mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-01-09 09:21:03 +01:00
Compare commits
7 Commits
da09adeeb6
...
9fe76c2662
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9fe76c2662 | ||
|
|
ddc77ffebb | ||
|
|
978714ab90 | ||
|
|
ed39702126 | ||
|
|
56151da67d | ||
|
|
a1bbc19c0b | ||
|
|
1039614f0a |
@@ -1,4 +1,8 @@
|
||||
|
||||
## 2.1.37-2 (05-01-2026)
|
||||
- Align configuration mapping with addon_config and homeassistant_config
|
||||
- Migrate legacy /homeassistant/addons_config/joal data to the addon config folder
|
||||
|
||||
## 2.1.37 (23-12-2025)
|
||||
- Update to latest version from anthonyraymond/joal (changelog : https://github.com/anthonyraymond/joal/releases)
|
||||
- The Home Assistant project has deprecated support for the armv7, armhf and i386 architectures. Support wil be fully dropped in the upcoming Home Assistant 2025.12 release
|
||||
|
||||
@@ -6,7 +6,8 @@ hassio_api: true
|
||||
image: ghcr.io/alexbelgium/joal-{arch}
|
||||
ingress: true
|
||||
map:
|
||||
- config:rw
|
||||
- addon_config:rw
|
||||
- homeassistant_config:rw
|
||||
name: Joal
|
||||
options:
|
||||
env_vars: []
|
||||
@@ -32,4 +33,4 @@ schema:
|
||||
slug: joal
|
||||
udev: true
|
||||
url: https://github.com/alexbelgium/hassio-addons
|
||||
version: "2.1.37"
|
||||
version: 2.1.37-2
|
||||
|
||||
@@ -33,15 +33,25 @@ bashio::log.info "Joal updated"
|
||||
# SYMLINK CONFIG #
|
||||
##################
|
||||
|
||||
slug=joal
|
||||
|
||||
# Migrate legacy config location
|
||||
if [ -d "/homeassistant/addons_config/$slug" ] \
|
||||
&& [ ! -f "/homeassistant/addons_config/$slug/migrated" ] \
|
||||
&& [ -n "$(find "/homeassistant/addons_config/$slug" -mindepth 1 -maxdepth 1 -print -quit)" ]; then
|
||||
bashio::log.info "Migrating /homeassistant/addons_config/$slug to /addon_configs/xxx-$slug"
|
||||
cp -rnf /homeassistant/addons_config/"$slug"/* /config/ || true
|
||||
mv /homeassistant/addons_config/"$slug" /homeassistant/addons_config/"$slug"_migrated
|
||||
fi
|
||||
|
||||
# If config doesn't exist, create it
|
||||
if [ ! -f /config/addons_config/joal/config.yaml ]; then
|
||||
if [ ! -f /config/config.json ]; then
|
||||
bashio::log.info "Symlinking config files"
|
||||
mkdir -p /config/addons_config/joal
|
||||
cp /data/joal/config.yaml /config/addons_config/joal/config.yaml
|
||||
cp /data/joal/config.json /config/config.json
|
||||
fi
|
||||
|
||||
# Refresh symlink
|
||||
ln -sf /config/addons_config/joal/config.yaml /data/joal/config.yaml
|
||||
ln -sf /config/config.json /data/joal/config.json
|
||||
|
||||
###############
|
||||
# SET VARIABLES #
|
||||
@@ -63,6 +73,12 @@ UIPATH=$(bashio::config 'ui_path')
|
||||
#port=$(bashio::addon.port 80)
|
||||
ingress_port=$(bashio::addon.ingress_port)
|
||||
ingress_interface=$(bashio::addon.ip_address)
|
||||
ui_credentials_json=$(jq -n --arg host "${host_ip}:${host_port}${ingress_url}/" \
|
||||
--arg port "${host_port}" \
|
||||
--arg pathPrefix "${UIPATH}" \
|
||||
--arg secretToken "${TOKEN}" \
|
||||
'{host:$host,port:$port,pathPrefix:$pathPrefix,secretToken:$secretToken}')
|
||||
ui_credentials_encoded=$(printf '%s' "$ui_credentials_json" | jq -sRr @uri)
|
||||
|
||||
#################
|
||||
# NGINX SETTING #
|
||||
@@ -80,6 +96,7 @@ ingress_interface=$(bashio::addon.ip_address)
|
||||
sed -i "s/%%port%%/${ingress_port}/g" /etc/nginx/servers/ingress.conf
|
||||
sed -i "s/%%interface%%/${ingress_interface}/g" /etc/nginx/servers/ingress.conf
|
||||
sed -i "s/%%path%%/${UIPATH}/g" /etc/nginx/servers/ingress.conf
|
||||
sed -i "s|%%ui_credentials%%|${ui_credentials_encoded}|g" /etc/nginx/servers/ingress.conf
|
||||
mkdir -p /var/log/nginx && touch /var/log/nginx/error.log
|
||||
|
||||
###############
|
||||
|
||||
@@ -12,7 +12,7 @@ server {
|
||||
proxy_connect_timeout 30m;
|
||||
proxy_send_timeout 30m;
|
||||
proxy_read_timeout 30m;
|
||||
proxy_pass http://backend/%%path%%/ui/;
|
||||
proxy_pass http://backend/%%path%%/ui?ui_credentials=%%ui_credentials%%;
|
||||
}
|
||||
|
||||
location /:8123/ {
|
||||
|
||||
Reference in New Issue
Block a user