Update 99-run.sh

This commit is contained in:
Alexandre
2021-11-18 08:24:58 +01:00
committed by GitHub
parent dc03e52be4
commit c453877248

View File

@@ -3,7 +3,6 @@
################## ##################
# INITIALIZATION # # INITIALIZATION #
################## ##################
EXIT_CODE=0
# Where is the config # Where is the config
CONFIGSOURCE=$(bashio::config "CONFIG_LOCATION") CONFIGSOURCE=$(bashio::config "CONFIG_LOCATION")
@@ -25,6 +24,7 @@ if [ -f $CONFIGSOURCE ]; then
bashio::log.info "Using config file found in $CONFIGSOURCE" bashio::log.info "Using config file found in $CONFIGSOURCE"
# Check if yaml is valid # Check if yaml is valid
EXIT_CODE=0
yamllint -d relaxed --no-warnings $CONFIGSOURCE &> ERROR || EXIT_CODE=$? yamllint -d relaxed --no-warnings $CONFIGSOURCE &> ERROR || EXIT_CODE=$?
if [ $EXIT_CODE = 0 ]; then if [ $EXIT_CODE = 0 ]; then
echo "Config file is a valid yaml" echo "Config file is a valid yaml"