add quacamole sqlpage
This commit is contained in:
parent
337df6c751
commit
a31db48ad0
43 changed files with 421 additions and 14 deletions
19
ressources/homeassistant/README.MD
Normal file
19
ressources/homeassistant/README.MD
Normal file
|
@ -0,0 +1,19 @@
|
|||
#### homeassistant
|
||||
|
||||
##### Information
|
||||
Site : https://www.home-assistant.io
|
||||
|
||||
Source : https://github.com/home-assistant
|
||||
|
||||
##### Install
|
||||
|
||||
```bash
|
||||
apt install -y wget ca-certificates
|
||||
wget -qO - https://deb.lgy.fr/install.sh | bash
|
||||
apt-get update
|
||||
|
||||
|
||||
apt-get install -y homeassistant
|
||||
|
||||
systemctl enable --now homeassistant
|
||||
```
|
32
ressources/homeassistant/debmaker
Executable file
32
ressources/homeassistant/debmaker
Executable file
|
@ -0,0 +1,32 @@
|
|||
#!/bin/bash
|
||||
|
||||
VERSION=2023.10.3
|
||||
APP=homeassistant
|
||||
DEPOT=https://github.com/home-assistant/core.git
|
||||
GIT_VERSION=${VERSION}
|
||||
DEB_VERSION=${VERSION}-$(date +%Y%m%d%H%M)
|
||||
DEBIAN_VERSION_CODENAME=bookworm
|
||||
IMAGE_SIZE=10
|
||||
PACKAGE_DEPENDENCY=""
|
||||
|
||||
main(){
|
||||
base_package_upgrade
|
||||
install_package_dependency
|
||||
get_git_source
|
||||
#makedeb
|
||||
}
|
||||
|
||||
makedeb(){
|
||||
PATH_DEB=/tmp/src/rootfs
|
||||
|
||||
mkdir -p ${PATH_DEB}/etc/babybuddy/
|
||||
mv /tmp/${APP}/babybuddy/settings/production.example.py ${PATH_DEB}/etc/babybuddy/production.py
|
||||
|
||||
mkdir -p ${PATH_DEB}/usr/share/
|
||||
cp -fr /tmp/${APP}/ ${PATH_DEB}/usr/share/
|
||||
|
||||
ln -s /etc/babybuddy/production.py ${PATH_DEB}/usr/share/babybuddy/babybuddy/settings/production.py
|
||||
|
||||
sed -i "s/%VERSION%/$DEB_VERSION/" ${PATH_DEB}/DEBIAN/control
|
||||
fakeroot dpkg-deb -Z gzip --build ${PATH_DEB} /tmp/dist
|
||||
}
|
0
ressources/homeassistant/rootfs/DEBIAN/changelog
Normal file
0
ressources/homeassistant/rootfs/DEBIAN/changelog
Normal file
1
ressources/homeassistant/rootfs/DEBIAN/conffiles
Normal file
1
ressources/homeassistant/rootfs/DEBIAN/conffiles
Normal file
|
@ -0,0 +1 @@
|
|||
/etc/babybuddy/production.py
|
8
ressources/homeassistant/rootfs/DEBIAN/control
Normal file
8
ressources/homeassistant/rootfs/DEBIAN/control
Normal file
|
@ -0,0 +1,8 @@
|
|||
Package: babybuddy
|
||||
Version: %VERSION%
|
||||
Section: contrib
|
||||
Priority: optional
|
||||
Architecture: all
|
||||
Depends: python3 ( >= 3.7 ), python-is-python3, python3-venv
|
||||
Maintainer: Thomas Legay <thomas@lgy.fr>
|
||||
Description: babybuddy
|
19
ressources/homeassistant/rootfs/DEBIAN/postinst
Executable file
19
ressources/homeassistant/rootfs/DEBIAN/postinst
Executable file
|
@ -0,0 +1,19 @@
|
|||
#!/bin/bash
|
||||
APP=homeassistant
|
||||
HOMEDIR=/var/lib/homeassistant/
|
||||
|
||||
[ -d ${HOMEDIR} ] || mkdir -p ${HOMEDIR}
|
||||
id ${APP} &> /dev/null || useradd ${APP} -r -s /bin/false -d ${HOMEDIR}
|
||||
|
||||
chown ${APP}:${APP} ${HOMEDIR}
|
||||
|
||||
systemctl | grep ${APP} | grep -q running && systemctl daemon-reload && systemctl restart ${APP}
|
||||
|
||||
if [[ $(systemctl list-unit-files | grep ${APP}.services) -eq 0 ]]
|
||||
then
|
||||
systemctl daemon-reload
|
||||
if [ "$(systemctl is-active ${APP}.service)" != "inactive" ]
|
||||
then
|
||||
systemctl restart ${APP}
|
||||
fi
|
||||
fi
|
1
ressources/homeassistant/rootfs/etc/default/babybuddy
Normal file
1
ressources/homeassistant/rootfs/etc/default/babybuddy
Normal file
|
@ -0,0 +1 @@
|
|||
DJANGO_SETTINGS_MODULE=babybuddy.settings.production
|
|
@ -0,0 +1,20 @@
|
|||
[Unit]
|
||||
Description=homeassistant
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
User=homeassistant
|
||||
Group=homeassistant
|
||||
EnvironmentFile=/etc/default/homeassistant
|
||||
ExecStartPre=python3 -m venv /var/lib/homeassistant/.venv
|
||||
ExecStartPre=/var/lib/homeassistant/.venv/bin/pip install -r /usr/share/homeassistant/requirements.txt
|
||||
ExecStartPre=/var/lib/homeassistant/.venv/bin/python3 /usr/share/homeassistant/manage.py migrate
|
||||
ExecStartPre=/var/lib/homeassistant/.venv/bin/python3 /usr/share/homeassistant/manage.py createcachetable
|
||||
ExecStart=/var/lib/homeassistant/.venv/bin/python3 /usr/share/homeassistant/manage.py runserver 0.0.0.0:8000
|
||||
WorkingDirectory=/var/lib/homeassistant
|
||||
StandardOutput=inherit
|
||||
StandardError=inherit
|
||||
Restart=always
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
Loading…
Add table
Add a link
Reference in a new issue