From 5b2ffb277dfccf82fd5587e900a692b0af911787 Mon Sep 17 00:00:00 2001 From: Alexandre <44178713+alexbelgium@users.noreply.github.com> Date: Fri, 14 Jan 2022 21:58:47 +0100 Subject: [PATCH] Update 90-config_yaml.sh --- zzz_templates/90-config_yaml.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/zzz_templates/90-config_yaml.sh b/zzz_templates/90-config_yaml.sh index 9c16c56a5..bad0832cb 100644 --- a/zzz_templates/90-config_yaml.sh +++ b/zzz_templates/90-config_yaml.sh @@ -81,10 +81,10 @@ while IFS= read -r line; do fi # Data validation if [[ $line =~ ^.+[=].+$ ]]; then - export $line + export $line 2> /dev/null # Export the variable - sed -i "1a export $line" /etc/services.d/*/*run* 2>/dev/null || true - sed -i "1a export $line" /etc/cont-init.d/*run* 2>/dev/null + [ -f /etc/services.d/*/*run* ] && sed -i "1a export $line 2>/dev/null || true" /etc/services.d/*/*run* || true + [ -f /etc/cont-init.d/*run* ] && sed -i "1a export $line 2>/dev/null || true" /etc/cont-init.d/*run* || true # Show in log if ! bashio::config.false "verbose"; then bashio::log.blue "$line"; fi else