revert 152ab76a2e
revert Actualiser cookcli/rootfs/etc/services.d/cookcli/run
This commit is contained in:
parent
3a0e023744
commit
6d7d9be778
|
|
@ -6,28 +6,9 @@ bashio::log.info "=== Démarrage du service CookCLI ==="
|
||||||
|
|
||||||
RECIPES_PATH=$(bashio::config 'recipes_path')
|
RECIPES_PATH=$(bashio::config 'recipes_path')
|
||||||
PORT=9081
|
PORT=9081
|
||||||
|
LOG_LEVEL=$(bashio::config 'log_level')
|
||||||
|
|
||||||
# Récupérer le chemin Ingress
|
exec /usr/local/bin/cook server "${RECIPES_PATH}" \
|
||||||
INGRESS_TOKEN=$(bashio::config 'ingress_token')
|
|
||||||
if [ -n "$INGRESS_TOKEN" ]; then
|
|
||||||
INGRESS_PATH="/api/hassio_ingress/${INGRESS_TOKEN}"
|
|
||||||
bashio::log.info "Chemin Ingress: ${INGRESS_PATH}"
|
|
||||||
else
|
|
||||||
INGRESS_PATH=""
|
|
||||||
fi
|
|
||||||
|
|
||||||
bashio::log.info "Démarrage de CookCLI sur le port ${PORT}..."
|
|
||||||
|
|
||||||
# Si CookCLI supporte --base-path
|
|
||||||
if [ -n "$INGRESS_PATH" ]; then
|
|
||||||
exec /usr/local/bin/cook server "${RECIPES_PATH}" \
|
|
||||||
--port "${PORT}" \
|
|
||||||
--host "0.0.0.0" \
|
|
||||||
"${INGRESS_PATH}" \
|
|
||||||
>> /proc/1/fd/1 2>&1
|
|
||||||
else
|
|
||||||
exec /usr/local/cook server "${RECIPES_PATH}" \
|
|
||||||
--port "${PORT}" \
|
--port "${PORT}" \
|
||||||
--host "0.0.0.0" \
|
--host "0.0.0.0" \
|
||||||
>> /proc/1/fd/1 2>&1
|
>> /proc/1/fd/1 2>&1
|
||||||
fi
|
|
||||||
Loading…
Reference in a new issue