File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- # Use an official Python runtime as a parent image
21FROM python:3.9-slim
32
4- # Set the working directory in the container
53WORKDIR /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
99RUN pip install --no-cache-dir requests
1010
11- # Copy the current directory contents into the container at /app
1211COPY 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"]
You can’t perform that action at this time.
0 commit comments