Skip to content

Commit 486bb50

Browse files
authored
Update dockerfile
1 parent 0281cc1 commit 486bb50

1 file changed

Lines changed: 6 additions & 8 deletions

File tree

dockerfile

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,14 @@
1-
# Use an official Python runtime as a parent image
21
FROM python:3.9-slim
32

4-
# Set the working directory in the container
53
WORKDIR /app
64

7-
# Install any necessary dependencies
8-
# We install requests directly since it's the only one
5+
# Install curl for the healthcheck
6+
RUN apt-get update && apt-get install -y curl && rm -rf /var/lib/apt/lists/*
7+
8+
# Install python dependencies
99
RUN pip install --no-cache-dir requests
1010

11-
# Copy the current directory contents into the container at /app
1211
COPY main.py .
1312

14-
# Set the entrypoint to python and the script
15-
# This allows you to pass arguments directly to the docker run command
16-
ENTRYPOINT ["python", "main.py"]
13+
# Use CMD instead of ENTRYPOINT for better environment variable handling
14+
CMD ["python", "main.py"]

0 commit comments

Comments
 (0)