Skip to content

Commit

Permalink
bugfix
Browse files Browse the repository at this point in the history
Python Version Update from 3.10 to 3.13 and set static pip packages version
  • Loading branch information
Tob1as committed Oct 28, 2024
1 parent 43ff130 commit cc9e332
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 21 deletions.
15 changes: 8 additions & 7 deletions python.alpine.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM python:3.10-alpine
FROM python:3.13-alpine

ARG VCS_REF
ARG BUILD_DATE
Expand Down Expand Up @@ -27,16 +27,17 @@ RUN \
libgpiod \
mariadb-connector-c \
; \
pip3 install --no-cache-dir rpi.gpio; \
#pip3 install --no-cache-dir sysv-ipc; \
pip3 install --no-cache-dir adafruit-circuitpython-dht; \
pip3 install --no-cache-dir mariadb==1.0.11; \
pip3 install --no-cache-dir paho-mqtt; \
pip3 install --no-cache-dir rpi.gpio==0.7.1; \
#pip3 install --no-cache-dir sysv-ipc==1.1.0; \
pip3 install --no-cache adafruit-blinka==8.44.4 ; \
pip3 install --no-cache-dir adafruit-circuitpython-dht==4.0.5; \
pip3 install --no-cache-dir mariadb==1.1.10; \
pip3 install --no-cache-dir paho-mqtt==2.1.0; \
apk del --no-network --purge .build-deps; \
chmod +x /service/*.py

WORKDIR /service

STOPSIGNAL SIGINT

CMD ["python3", "-u", "./dht_sensor.py"]
CMD ["python3", "-u", "./dht_sensor.py"]
15 changes: 8 additions & 7 deletions python.debian.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM python:3.10-slim
FROM python:3.13-slim

ARG VCS_REF
ARG BUILD_DATE
Expand Down Expand Up @@ -28,16 +28,17 @@ RUN \
libmariadb3 \
; \
rm -rf /var/lib/apt/lists/*; \
pip3 install --no-cache-dir rpi.gpio; \
#pip3 install --no-cache-dir sysv-ipc; \
pip3 install --no-cache-dir adafruit-circuitpython-dht; \
pip3 install --no-cache-dir mariadb==1.0.11; \
pip3 install --no-cache-dir paho-mqtt; \
pip3 install --no-cache-dir rpi.gpio==0.7.1; \
#pip3 install --no-cache-dir sysv-ipc==1.1.0; \
pip3 install --no-cache adafruit-blinka==8.44.4 ; \
pip3 install --no-cache-dir adafruit-circuitpython-dht==4.0.5; \
pip3 install --no-cache-dir mariadb==1.1.10; \
pip3 install --no-cache-dir paho-mqtt==2.1.0; \
apt-get remove --purge -y $BUILD_PACKAGES; apt autoremove -y ; \
chmod +x /service/*.py

WORKDIR /service

STOPSIGNAL SIGINT

CMD ["python3", "-u", "./dht_sensor.py"]
CMD ["python3", "-u", "./dht_sensor.py"]
8 changes: 4 additions & 4 deletions python.mqtt2sql.alpine.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM python:3.10-alpine
FROM python:3.13-alpine

ARG VCS_REF
ARG BUILD_DATE
Expand Down Expand Up @@ -29,8 +29,8 @@ RUN \
apk add --no-cache \
mariadb-connector-c \
; \
pip3 install --no-cache-dir mariadb==1.0.11; \
pip3 install --no-cache-dir paho-mqtt; \
pip3 install --no-cache-dir mariadb==1.1.10; \
pip3 install --no-cache-dir paho-mqtt==2.1.0; \
apk del --no-network --purge .build-deps; \
chmod +x /service/*.py ; \
\
Expand All @@ -43,4 +43,4 @@ USER service

STOPSIGNAL SIGINT

CMD ["python3", "-u", "/service/mqtt2sql.py"]
CMD ["python3", "-u", "/service/mqtt2sql.py"]
6 changes: 3 additions & 3 deletions python_git.alpine.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM python:3.10-alpine
FROM python:3.13-alpine

ARG VCS_REF
ARG BUILD_DATE
Expand Down Expand Up @@ -34,7 +34,7 @@ RUN \
; \
pip3 install --no-cache-dir rpi.gpio; \
#pip3 install --no-cache-dir sysv-ipc; \
pip3 install --no-cache-dir mariadb==1.0.11; \
pip3 install --no-cache-dir mariadb; \
pip3 install --no-cache-dir paho-mqtt; \
###################
## Install with PIP
Expand All @@ -55,4 +55,4 @@ WORKDIR /service

STOPSIGNAL SIGINT

CMD ["python3", "-u", "./dht_sensor.py"]
CMD ["python3", "-u", "./dht_sensor.py"]

0 comments on commit cc9e332

Please sign in to comment.