mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-06-16 04:19:13 +02:00
Update 99-run.sh
This commit is contained in:
@@ -74,7 +74,7 @@ do
|
|||||||
echo "secret detected"
|
echo "secret detected"
|
||||||
secret=${line#*secret }
|
secret=${line#*secret }
|
||||||
# Check if single match
|
# Check if single match
|
||||||
[[ "$(sed -n "/$secret:/=" /config/secrets.yaml)" == *' '* ]] && bashio::log.fatal "There are multiple matches for your password name. Please check your secrets.yaml file" && continue
|
[[ "$(sed -n "/$secret:/=" /config/secrets.yaml)" == *' '* ]] && bashio::log.fatal "There are multiple matches for your password name. Please check your secrets.yaml file" && bashio::addon.stop
|
||||||
# Get text
|
# Get text
|
||||||
secret=$(sed -n "/$secret:/p" /config/secrets.yaml)
|
secret=$(sed -n "/$secret:/p" /config/secrets.yaml)
|
||||||
secret=${secret#*: }
|
secret=${secret#*: }
|
||||||
@@ -85,8 +85,8 @@ do
|
|||||||
export $line # Export the variable
|
export $line # Export the variable
|
||||||
bashio::log.blue "$line"
|
bashio::log.blue "$line"
|
||||||
else
|
else
|
||||||
bashio::log.fatal "$line does not follow the structure KEY=text, it will be ignored and removed from the config"
|
bashio::log.fatal "$line does not follow the structure KEY=text"
|
||||||
sed -i "/$line/ d" ${CONFIGSOURCE}
|
bashio::addon.stop
|
||||||
fi
|
fi
|
||||||
done < "/tmpfile"
|
done < "/tmpfile"
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user