LoginSignup
2
4

More than 5 years have passed since last update.

MQTT: mosquittoをwebsocket対応にするには

Last updated at Posted at 2018-03-05

mosquittoの設定

/etc/mosquitto/mosquitto.config
の最後に以下の行を追加する。

mosquitto.config
listener 1883
listener 9001
protocol websockets

そして

$ sudo systemctl restart mosquitto

これで通常の1883ポートによるmqtt接続に加えて、9001ポートを利用しwebsocketでmosquittoに接続することができるようになる。

2
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
4