From 90642bd1ebbcdf1396ec6f54464292acf0e68068 Mon Sep 17 00:00:00 2001 From: Roman Stein Date: Wed, 2 Dec 2020 00:20:17 +0100 Subject: [PATCH] Add new v1.16.2 configuration options to edge --- zigbee2mqtt-edge/config.json | 6 ++++-- zigbee2mqtt-edge/run.sh | 2 ++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/zigbee2mqtt-edge/config.json b/zigbee2mqtt-edge/config.json index 50e817a..1fb7d7e 100644 --- a/zigbee2mqtt-edge/config.json +++ b/zigbee2mqtt-edge/config.json @@ -94,7 +94,8 @@ "keepalive": "int?", "version": "int?", "reject_unauthorized": "bool?", - "include_device_information": "bool?" + "include_device_information": "bool?", + "force_disable_retain": "bool?" }, "serial": { "port": "str", @@ -157,6 +158,7 @@ "new_api": "bool?" }, "frontend": { + "host": "string?", "port": "int?" }, "socat": { @@ -170,4 +172,4 @@ } }, "image": "dwelch2101/zigbee2mqtt-edge-{arch}" -} \ No newline at end of file +} diff --git a/zigbee2mqtt-edge/run.sh b/zigbee2mqtt-edge/run.sh index 35f3a90..372b73d 100644 --- a/zigbee2mqtt-edge/run.sh +++ b/zigbee2mqtt-edge/run.sh @@ -29,6 +29,8 @@ mkdir -p "$DATA_PATH" # Parse config cat "$CONFIG_PATH" | jq 'del(.data_path, .zigbee_shepherd_debug, .zigbee_shepherd_devices, .socat)' \ + | jq 'if .devices then .devices = (.devices | split(",")|map(gsub("\\s+";"";"g"))) else . end' \ + | jq 'if .groups then .groups = (.groups | split(",")|map(gsub("\\s+";"";"g"))) else . end' \ | jq 'if .advanced.ext_pan_id_string then .advanced.ext_pan_id = (.advanced.ext_pan_id_string | (split(",")|map(tonumber))) | del(.advanced.ext_pan_id_string) else . end' \ | jq 'if .advanced.network_key_string then .advanced.network_key = (.advanced.network_key_string | (split(",")|map(tonumber))) | del(.advanced.network_key_string) else . end' \ | jq 'if .device_options_string then .device_options = (.device_options_string|fromjson) | del(.device_options_string) else . end' \