fixed mqtt and sockets and reverse proxy after 5 hours

This commit is contained in:
2024-12-02 13:44:15 +01:00
parent 8aa54805ac
commit dd39bd3021
6 changed files with 40 additions and 7 deletions

View File

@@ -10,7 +10,7 @@ def on_message(client, userdata, message):
# Create an MQTT client instance
mqtt_client = mqtt.Client()
mqtt_client.username_pw_set("server", "serverwachtwoordofzo")
mqtt_client.connect("localhost", 1884, 60)
mqtt_client.connect("145.92.224.21/ws", 80, 60)
mqtt_client.loop_start()
mqtt_client.subscribe("kobuki/data")
mqtt_client.on_message = on_message # this lines needs to be under the function definition otherwise it cant find which function it needs to use