mirror of
https://github.com/tsightler/ring-mqtt.git
synced 2025-09-26 21:01:12 +08:00
Update init scripts
This commit is contained in:
@@ -4,12 +4,7 @@
|
||||
# s6-overlay docs: https://github.com/just-containers/s6-overlay
|
||||
# ==============================================================================
|
||||
|
||||
echo $1
|
||||
echo $2
|
||||
|
||||
if [[ "$1" -ne 0 ]] && [[ "$1" -ne 256 ]]; then
|
||||
bashio::log.warning "The ring-mqtt container is shutting down..."
|
||||
bashio::log.warning "A critical error was detected, exiting the container..."
|
||||
exec /run/s6/basedir/bin/halt
|
||||
fi
|
||||
|
||||
bashio::log.warning "The ring-mqtt service exited unexpectedly, restarting..."
|
@@ -14,7 +14,7 @@ sleep .5
|
||||
# If HASSIO_TOKEN variable exist we are running as addon
|
||||
if [ -v HASSIO_TOKEN ]; then
|
||||
export RUNMODE="addon"
|
||||
bashio::config.require 'mqtt_url'
|
||||
bashio::config.require 'mqtt_url_2'
|
||||
|
||||
if bashio::services.available 'mqtt'; then
|
||||
export BRANCH=$(bashio::config "branch")
|
||||
|
Reference in New Issue
Block a user