aboutsummaryrefslogtreecommitdiffstats
path: root/mqtt-client
diff options
context:
space:
mode:
Diffstat (limited to 'mqtt-client')
-rw-r--r--mqtt-client/Dockerfile8
-rw-r--r--mqtt-client/mqtt-client.py8
2 files changed, 8 insertions, 8 deletions
diff --git a/mqtt-client/Dockerfile b/mqtt-client/Dockerfile
index 12c8a53..be304a1 100644
--- a/mqtt-client/Dockerfile
+++ b/mqtt-client/Dockerfile
@@ -1,12 +1,12 @@
-FROM debian:11-slim
+FROM debian:12-slim
ENV TZ=Europe/London
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
RUN apt-get update -y
RUN apt-get install -y python3-pip iputils-ping
COPY . /app
WORKDIR /app
-RUN pip3 install -r requirements.txt
-RUN pip3 install docker
-RUN pip3 install -r TasmotaCLI/requirements.txt
+RUN pip3 install --break-system-packages -r requirements.txt
+RUN pip3 install --break-system-packages docker
+RUN pip3 install --break-system-packages -r TasmotaCLI/requirements.txt
ENTRYPOINT ["python3"]
CMD ["mqtt-client.py"]
diff --git a/mqtt-client/mqtt-client.py b/mqtt-client/mqtt-client.py
index d4279e9..6940df2 100644
--- a/mqtt-client/mqtt-client.py
+++ b/mqtt-client/mqtt-client.py
@@ -90,10 +90,10 @@ class MQTTClient:
def handle_zigbee(self, msg_j):
def toggle_firestick():
print("Starting thread...")
- tasmotaMQTTClient.MQTTClient(MQTT_HOST, "TasmotaFirestick", os.environ["MQTT_USER"], os.environ["MQTT_PASSWD"], "TOGGLE")
- #print("Waiting...")
- #time.sleep(8)
- #tasmotaMQTTClient.MQTTClient(MQTT_HOST, "TasmotaFirestick", os.environ["MQTT_USER"], os.environ["MQTT_PASSWD"], "ON")
+ tasmotaMQTTClient.MQTTClient(MQTT_HOST, "TasmotaFirestick", os.environ["MQTT_USER"], os.environ["MQTT_PASSWD"], "OFF")
+ print("Waiting...")
+ time.sleep(8)
+ tasmotaMQTTClient.MQTTClient(MQTT_HOST, "TasmotaFirestick", os.environ["MQTT_USER"], os.environ["MQTT_PASSWD"], "ON")
print("Toggled firestick.")
zigbee_id = list(msg_j["ZbReceived"].keys())[0]