From 9c24a8658fc98ff4a1346793be59bc85686743a7 Mon Sep 17 00:00:00 2001 From: Kevin Veen-Birkenbach Date: Sat, 5 Jul 2025 11:06:42 +0200 Subject: [PATCH] Solved other port mapping issues --- Dockerfile | 3 +-- main.py | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 932cdd4..2ac2e12 100644 --- a/Dockerfile +++ b/Dockerfile @@ -11,5 +11,4 @@ RUN pip install --no-cache-dir -r requirements.txt # Copy application code COPY app/ . -# Start command using shell to allow env substitution -CMD sh -c "exec python app.py --port=\${PORT}" +CMD ["python", "app.py"] diff --git a/main.py b/main.py index e5bf450..72ec938 100755 --- a/main.py +++ b/main.py @@ -125,7 +125,7 @@ def run_prod(args): """ command = [ "docker", "run", "-d", - "-p", "{PORT}:{PORT}", + "-p", "{PORT}:5000", "--name", "portfolio", "application-portfolio" ]