RongTsai4Git / TechNote

0 stars 0 forks source link

mosquitto bridge -> Azure IoTHub #1

Open RongTsai4Git opened 2 years ago

RongTsai4Git commented 2 years ago

Using below command to the configuration password file

For first: sudo mosquitto_passwd -c pwdfile.cfg {username}

After first: sudo mosquitto_passwd -b pwdfile.cfg {username} {password}

password_file /etc/mosquitto/pwdfile.cfg

Bridge

connection iothub-bridge address {iothub name}.azure-devices.net:8883 remote_username {iothub username} remote_password {SAS Token} remote_clientid {device id}

To find an available cert file by yourself

bridge_cafile /etc/ssl/certs/ca-certificates.crt

try_private false cleansession true start_type automatic bridge_protocol_version mqttv311 notifications false bridge_tls_version tlsv1.2

Bridge topic

topic # out 0 devices/{device id}/messages/events/ devices/{device id}/messages/events/ topic # in 0 devices/{device id}/messages/devicebound/ devices/{device id}/messages/devicebound/

RongTsai4Git commented 2 years ago

Tech reference mosquitto-bridge mosquitto-conf mosquitto-bridge-configuration how-mqtt-microsoft-azure-iot-hub-satish-pagare