From 3292dc270510561da62e5f86fef07cf8fc97b533 Mon Sep 17 00:00:00 2001 From: Alexandre <44178713+alexbelgium@users.noreply.github.com> Date: Tue, 16 Nov 2021 23:43:13 +0100 Subject: [PATCH] Update 00-aab.sh --- enedisgateway2mqtt_test/rootfs/scripts/00-aab.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/enedisgateway2mqtt_test/rootfs/scripts/00-aab.sh b/enedisgateway2mqtt_test/rootfs/scripts/00-aab.sh index 0597ccf48..09d98a2ce 100644 --- a/enedisgateway2mqtt_test/rootfs/scripts/00-aab.sh +++ b/enedisgateway2mqtt_test/rootfs/scripts/00-aab.sh @@ -1,14 +1,14 @@ #!/bin/bash -########################## -# Read all addon options # -########################## +################################### +# Export all addon options as env # +################################### # For all keys in options.json JSONSOURCE="/data/options.json" -mapfile -t arr < <(jq -r 'keys[]' ${JSONSOURCE}) -# Export keys as env variables +# Export keys as env variables +mapfile -t arr < <(jq -r 'keys[]' ${JSONSOURCE}) for KEYS in ${arr[@]}; do # export key export $(echo "${KEYS}=$(jq .$KEYS ${JSONSOURCE})")