net/mosquitto: port is optional in root config
authorKarl Palsson <karlp@etactica.com>
Mon, 26 Apr 2021 09:36:49 +0000 (09:36 +0000)
committerKarl Palsson <karlp@etactica.com>
Mon, 26 Apr 2021 09:38:42 +0000 (09:38 +0000)
From mosquitto 2.x, port became optional and deprecated in the config,
and it was recommended that listeners be used instead.  Drop the hard
requirement in our config conversion script.

Reported in: https://github.com/openwrt/packages/issues/15506
Signed-off-by: <karlp@etactica.com>
net/mosquitto/files/etc/init.d/mosquitto

index d6f2a44954e4c455d473fff1ed99d398f81b8aea..603b988eb9e98c5c1c6fa8d451ae65767fc3faef 100755 (executable)
@@ -63,8 +63,7 @@ convert_mosq_general() {
                echo "bind_address localhost" >> $TCONF
        fi
 
-       config_get port "$1" port 1883
-       echo "port $port" >> $TCONF
+       append_if "$1" port
        append_if "$1" acl_file
        append_optional_bool "$1" allow_anonymous
        append_optional_bool "$1" allow_duplicate_messages