Use python:3-alpine image for code execution (#1192)

This commit is contained in:
rickythefox
2023-04-17 17:45:23 +02:00
committed by GitHub
parent 7fd55fa2f4
commit baf31e69e5

View File

@@ -40,10 +40,10 @@ def execute_python_file(file: str):
try:
client = docker.from_env()
# You can replace 'python:3.8' with the desired Python image/version
# You can replace this with the desired Python image/version
# You can find available Python images on Docker Hub:
# https://hub.docker.com/_/python
image_name = "python:3.10"
image_name = "python:3-alpine"
try:
client.images.get(image_name)
print(f"Image '{image_name}' found locally")