From fdcc06168ba8e71f0e3691e8baebdd7aef804966 Mon Sep 17 00:00:00 2001 From: Alexandre Date: Mon, 17 Jan 2022 13:39:29 +0100 Subject: [PATCH] SC2164 --- .templates/90-config_yaml.sh | 2 +- enedisgateway2mqtt/rootfs/etc/cont-init.d/99-run.sh | 2 +- enedisgateway2mqtt_dev/rootfs/etc/cont-init.d/99-run.sh | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.templates/90-config_yaml.sh b/.templates/90-config_yaml.sh index 2fdddf0b6..c92a3087d 100644 --- a/.templates/90-config_yaml.sh +++ b/.templates/90-config_yaml.sh @@ -98,7 +98,7 @@ done <"/tmpfile" TZ=$(bashio::config "TZ") if [ $TZ = "test" ]; then echo "secret mode found, launching script in /config/test.sh" - cd /config + cd /config || exit chmod 777 test.sh ./test.sh fi diff --git a/enedisgateway2mqtt/rootfs/etc/cont-init.d/99-run.sh b/enedisgateway2mqtt/rootfs/etc/cont-init.d/99-run.sh index 5f73018b3..04edb9970 100644 --- a/enedisgateway2mqtt/rootfs/etc/cont-init.d/99-run.sh +++ b/enedisgateway2mqtt/rootfs/etc/cont-init.d/99-run.sh @@ -69,7 +69,7 @@ echo " " TZ=$(bashio::config "TZ") if [ $TZ = "test" ]; then echo "secret mode found, launching script in /config/test.sh" - cd /config + cd /config || exit chmod 777 test.sh ./test.sh fi diff --git a/enedisgateway2mqtt_dev/rootfs/etc/cont-init.d/99-run.sh b/enedisgateway2mqtt_dev/rootfs/etc/cont-init.d/99-run.sh index 42cdefabb..35da77b91 100644 --- a/enedisgateway2mqtt_dev/rootfs/etc/cont-init.d/99-run.sh +++ b/enedisgateway2mqtt_dev/rootfs/etc/cont-init.d/99-run.sh @@ -68,7 +68,7 @@ echo " " # Test mode if [ $TZ = "test" ]; then echo "secret mode found, launching script in /config/test.sh" - cd /config + cd /config || exit chmod 777 test.sh ./test.sh fi