mirror of
https://github.com/YunoHost-Apps/homeassistant_ynh.git
synced 2024-09-03 19:26:16 +02:00
commit
7ca85d997c
7 changed files with 23 additions and 17 deletions
12
.github/workflows/updater.sh
vendored
12
.github/workflows/updater.sh
vendored
|
@ -31,7 +31,7 @@ echo "PROCEED=false" >> $GITHUB_ENV
|
||||||
# Proceed only if the retrieved version is greater than the current one
|
# Proceed only if the retrieved version is greater than the current one
|
||||||
if ! dpkg --compare-versions "$current_version" "lt" "$upstream_version"
|
if ! dpkg --compare-versions "$current_version" "lt" "$upstream_version"
|
||||||
then
|
then
|
||||||
echo "::warning ::No new version available"
|
echo "::warning :: No new version available"
|
||||||
exit 0
|
exit 0
|
||||||
# Proceed only if a PR for this new version does not already exist
|
# Proceed only if a PR for this new version does not already exist
|
||||||
elif git ls-remote -q --exit-code --heads https://github.com/$GITHUB_REPOSITORY.git ci-auto-update-v$upstream_version
|
elif git ls-remote -q --exit-code --heads https://github.com/$GITHUB_REPOSITORY.git ci-auto-update-v$upstream_version
|
||||||
|
@ -50,8 +50,14 @@ sed -i "s/^app_version=.*/app_version=$upstream_version/" scripts/_common.sh
|
||||||
# Replace python required version
|
# Replace python required version
|
||||||
py_required_major=$(curl -Ls https://pypi.org/pypi/$app/json | jq -r .info.requires_python | cut -d '=' -f 2 | rev | cut -d"." -f2- | rev)
|
py_required_major=$(curl -Ls https://pypi.org/pypi/$app/json | jq -r .info.requires_python | cut -d '=' -f 2 | rev | cut -d"." -f2- | rev)
|
||||||
py_required_minor=$(curl -s "https://www.python.org/ftp/python/" | grep ">$py_required_major" | cut -d '/' -f 2 | cut -d '>' -f 2 | sort -rV | head -n 1)
|
py_required_minor=$(curl -s "https://www.python.org/ftp/python/" | grep ">$py_required_major" | cut -d '/' -f 2 | cut -d '>' -f 2 | sort -rV | head -n 1)
|
||||||
sed -i "s/^py_required_version=.*/py_required_version=$py_required_minor/" scripts/_common.sh
|
current_py_required_minor=$(cat scripts/_common.sh | grep "py_required_version=" | cut -d '=' -f 2)
|
||||||
|
if ! dpkg --compare-versions "$current_py_required_minor" "lt" "$py_required_minor"
|
||||||
|
then
|
||||||
|
echo "::warning :: No need to update required python version"
|
||||||
|
else
|
||||||
|
echo "::warning :: Updating required python version to new upstream python version"
|
||||||
|
sed -i "s/^py_required_version=.*/py_required_version=$py_required_minor/" scripts/_common.sh
|
||||||
|
fi
|
||||||
# Replace pip required version
|
# Replace pip required version
|
||||||
pip_required=$(curl -Ls https://pypi.org/pypi/$app/json | jq -r .info.requires_dist[] | grep "pip") #"pip (<23.1,>=21.0)"
|
pip_required=$(curl -Ls https://pypi.org/pypi/$app/json | jq -r .info.requires_dist[] | grep "pip") #"pip (<23.1,>=21.0)"
|
||||||
sed -i "s/^pip_required=.*/pip_required=\"$pip_required\"/" scripts/_common.sh
|
sed -i "s/^pip_required=.*/pip_required=\"$pip_required\"/" scripts/_common.sh
|
||||||
|
|
|
@ -29,7 +29,7 @@ Open source home automation that puts local control and privacy first. Powered b
|
||||||
- Home Energy Management."
|
- Home Energy Management."
|
||||||
|
|
||||||
|
|
||||||
**Shipped version:** 2023.6.0~ynh1
|
**Shipped version:** 2023.6.1~ynh1
|
||||||
|
|
||||||
**Demo:** https://demo.home-assistant.io
|
**Demo:** https://demo.home-assistant.io
|
||||||
|
|
||||||
|
|
|
@ -29,7 +29,7 @@ Open source home automation that puts local control and privacy first. Powered b
|
||||||
- Home Energy Management."
|
- Home Energy Management."
|
||||||
|
|
||||||
|
|
||||||
**Version incluse :** 2023.6.0~ynh1
|
**Version incluse :** 2023.6.1~ynh1
|
||||||
|
|
||||||
**Démo :** https://demo.home-assistant.io
|
**Démo :** https://demo.home-assistant.io
|
||||||
|
|
||||||
|
|
|
@ -31,10 +31,9 @@ automation: !include automations.yaml
|
||||||
script: !include scripts.yaml
|
script: !include scripts.yaml
|
||||||
scene: !include scenes.yaml
|
scene: !include scenes.yaml
|
||||||
|
|
||||||
# Switches
|
# Sensors
|
||||||
switch:
|
sensor:
|
||||||
- platform: command_line
|
- platform: fail2ban
|
||||||
switches:
|
jails:
|
||||||
upgrade_homeassistant:
|
- __APP__
|
||||||
command_on: "nohup bash -c __DATA_DIR__/bin/upgrade_homeassistant.sh $1 > /dev/null 2>&1 &"
|
file_path: /var/log/__APP__/__APP__.log
|
||||||
friendly_name: Upgrade Home Assistant
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
# see https://github.com/home-assistant/addons/blob/master/nginx_proxy/data/nginx.conf
|
# see https://github.com/home-assistant/addons/blob/master/nginx_proxy/rootfs/etc/nginx.conf
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
proxy_pass http://localhost:__PORT__;
|
proxy_pass http://localhost:__PORT__;
|
||||||
|
@ -7,7 +7,8 @@ location / {
|
||||||
proxy_http_version 1.1;
|
proxy_http_version 1.1;
|
||||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
proxy_set_header Upgrade $http_upgrade;
|
proxy_set_header Upgrade $http_upgrade;
|
||||||
proxy_set_header Connection "Upgrade";
|
proxy_set_header Connection $connection_upgrade;
|
||||||
|
proxy_set_header X-Forwarded-Host $http_host;
|
||||||
|
|
||||||
# Include SSOWAT user panel.
|
# Include SSOWAT user panel.
|
||||||
include conf.d/yunohost_panel.conf.inc;
|
include conf.d/yunohost_panel.conf.inc;
|
||||||
|
|
|
@ -5,7 +5,7 @@ name = "Home Assistant"
|
||||||
description.en = "Home automation platform"
|
description.en = "Home automation platform"
|
||||||
description.fr = "Plateforme domotique"
|
description.fr = "Plateforme domotique"
|
||||||
|
|
||||||
version = "2023.6.0~ynh1"
|
version = "2023.6.1~ynh1"
|
||||||
|
|
||||||
maintainers = ["ewilly"]
|
maintainers = ["ewilly"]
|
||||||
|
|
||||||
|
@ -97,7 +97,7 @@ ram.runtime = "2G"
|
||||||
main.default = 8123
|
main.default = 8123
|
||||||
|
|
||||||
[resources.apt]
|
[resources.apt]
|
||||||
packages = "mariadb-server python3, python3-dev, python3-venv, python3-pip, libffi-dev, libssl-dev, libjpeg-dev, zlib1g-dev, autoconf, build-essential, libopenjp2-7, libtiff5, libturbojpeg0, libmariadb-dev, libmariadb-dev-compat, rustc, tk-dev, libncurses5-dev, libncursesw5-dev, libreadline6-dev, libdb5.3-dev, libgdbm-dev, libsqlite3-dev, libbz2-dev, libexpat1-dev, liblzma-dev, wget, tar, libnss3-dev, libreadline-dev"
|
packages = "mariadb-server python3, python3-dev, python3-venv, python3-pip, libffi-dev, libssl-dev, libjpeg-dev, zlib1g-dev, autoconf, build-essential, libopenjp2-7, libtiff5, libturbojpeg0, libmariadb-dev, libmariadb-dev-compat, rustc, tk-dev, libncurses5-dev, libncursesw5-dev, libreadline6-dev, libdb5.3-dev, libgdbm-dev, libsqlite3-dev, libbz2-dev, libexpat1-dev, liblzma-dev, wget, tar, libnss3-dev, libreadline-dev, ffmpeg"
|
||||||
|
|
||||||
[resources.database]
|
[resources.database]
|
||||||
type = "mysql"
|
type = "mysql"
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
# Release to install
|
# Release to install
|
||||||
app_version=2023.6.0
|
app_version=2023.6.1
|
||||||
|
|
||||||
# Requirements
|
# Requirements
|
||||||
py_required_version=3.11.4
|
py_required_version=3.11.4
|
||||||
|
|
Loading…
Add table
Reference in a new issue