Alexandre
2023-11-23 08:42:57 +01:00
parent e6649691f4
commit 8498e83a07
3 changed files with 7 additions and 4 deletions

View File

@@ -30,8 +30,9 @@ if bashio::config.has_value 'CONFIG_LOCATION'; then
# Get config source
CONFIGSOURCE=$(bashio::config "CONFIG_LOCATION")
# Check CONFIGSOURCE ends with config.yaml
if [ "$(basename "$CONFIGSOURCE")" != "config.yaml" ]; then
bashio::log.red "Watch-out: your CONFIG_LOCATION should end by config.yaml, and instead it is $(basename "$CONFIGSOURCE")"
if [ "$(basename "$CONFIGSOURCE")" != "*.yaml" ]; then
# Remove trailing slash and add config.yaml
CONFIGSOURCE="${CONFIGSOURCE%/}"/config.yaml
fi
# Check if config is located in an acceptable location
LOCATIONOK=""