Websockets not working in mosquitto 1.4.15-r6
Websockets does not seem to be working in mosquitto 1.4.15-r6. I'm just using default conf with protocol set to websockets, port to 9001 and connect using a simple Python script:
import paho.mqtt.client as mqtt
def on_connect(client, userdata, flags, rc):
print("Connected with result code "+str(rc))
client.subscribe("$SYS/#")
def on_message(client, userdata, msg):
print(msg.topic+" "+str(msg.payload))
client = mqtt.Client(transport='websockets')
client.on_connect = on_connect
client.on_message = on_message
client.connect("localhost", 9001, 60)
client.loop_forever()
This used to work in mosquitto 1.4.15-r4, using the Alpine 3.8 docker image.