mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-05-01 14:50:51 +02:00
Update 99-run.sh
This commit is contained in:
@@ -151,17 +151,25 @@ wait_minio_ready_and_bucket() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
start_web() {
|
start_web() {
|
||||||
if $DISABLE_WEB_UI; then
|
if $DISABLE_WEB_UI; then
|
||||||
bashio::log.info "Web UI disabled."
|
bashio::log.info "Web UI disabled."
|
||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
if [ -z "$WEB_BIN" ] || [ ! -x "$WEB_BIN" ]; then
|
|
||||||
bashio::log.warning "Web UI binary not found; skipping."
|
# Prepare static assets with actual origins (does safe sed replacements).
|
||||||
return 0
|
ENTE_API_ORIGIN="${ENTE_API_ORIGIN:-http://[HOST]:[PORT:8080]}"
|
||||||
fi
|
ENTE_ALBUMS_ORIGIN="${ENTE_ALBUMS_ORIGIN:-${ENTE_API_ORIGIN}}"
|
||||||
bashio::log.info "Starting Ente web (:3000)..."
|
export ENTE_API_ORIGIN ENTE_ALBUMS_ORIGIN
|
||||||
"$WEB_BIN" &
|
/usr/local/bin/ente-web-prepare || bashio::log.warning "Web env substitution step returned non‑zero; continuing."
|
||||||
WEB_PID=$!
|
|
||||||
|
# nginx expects runtime dirs
|
||||||
|
mkdir -p /run/nginx
|
||||||
|
# log dir
|
||||||
|
mkdir -p /var/log/nginx
|
||||||
|
|
||||||
|
bashio::log.info "Starting Ente web (nginx, ports 3000‑3004)..."
|
||||||
|
nginx -c /etc/ente-web/nginx.conf -g 'daemon off;' &
|
||||||
|
WEB_PID=$!
|
||||||
}
|
}
|
||||||
|
|
||||||
start_museum_foreground() {
|
start_museum_foreground() {
|
||||||
|
|||||||
Reference in New Issue
Block a user