Skip to content

Commit 6d5d0e5

Browse files
authored
Use bashio::services for the connection even when base_topic is specified in the config (#620)
1 parent 9697f9c commit 6d5d0e5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

common/rootfs/docker-entrypoint.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ function export_config() {
8989
export_config 'mqtt'
9090
export_config 'serial'
9191

92-
if bashio::config.is_empty 'mqtt' && bashio::var.has_value "$(bashio::services 'mqtt')"; then
92+
if (bashio::config.is_empty 'mqtt' || ! (bashio::config.has_value 'mqtt.server' || bashio::config.has_value 'mqtt.user' || bashio::config.has_value 'mqtt.password')) && bashio::var.has_value "$(bashio::services 'mqtt')"; then
9393
if bashio::var.true "$(bashio::services 'mqtt' 'ssl')"; then
9494
export ZIGBEE2MQTT_CONFIG_MQTT_SERVER="mqtts://$(bashio::services 'mqtt' 'host'):$(bashio::services 'mqtt' 'port')"
9595
else

0 commit comments

Comments
 (0)