Specify the base image version to fix dependency missing or version conflict issues when using apt-get.

The originally specified version 3.11-slim is only an alias representing the latest version in the 3.11.x-slim series (for example, on November 22nd, its exact version number was 3.11.14-slim). After the base image is updated, various unexpected errors may occur when executing apt-get.
This commit is contained in:
Frank Zhou
2025-11-23 00:03:26 +08:00
committed by GitHub
parent 782a933971
commit 889545f356
+2 -2
View File
@@ -1,5 +1,5 @@
FROM --platform=linux/amd64 python:3.11-slim FROM --platform=linux/amd64 python:3.11.12
ENV DEBIAN_FRONTEND=noninteractive ENV DEBIAN_FRONTEND=noninteractive
# Install essential packages and Chrome dependencies # Install essential packages and Chrome dependencies
@@ -100,4 +100,4 @@ COPY config.ini .
EXPOSE 8000 EXPOSE 8000
# Run the application # Run the application
CMD ["python3", "api.py"] CMD ["python3", "api.py"]