Skip to content

Commit

Permalink
add dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
giovanni.buroni committed Dec 11, 2024
1 parent 5b6bc0e commit 18a75f2
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Use an official Python runtime as a parent image
FROM python:3.9-slim

# Set the working directory inside the container
WORKDIR /app

# Install system dependencies required for building Python C extensions
RUN apt-get update && apt-get install -y \
curl \
build-essential \
gcc \
g++ \
libffi-dev \
libpq-dev \
&& rm -rf /var/lib/apt/lists/*

# Copy the requirements.txt file into the container at /app
COPY requirements.txt /app/

# Install the Python dependencies from requirements.txt
RUN pip install --no-cache-dir -r requirements.txt

# Copy the rest of the project files into the container at /app
COPY . /app

# Specify the command to run the application
CMD ["python", "main.py"]

0 comments on commit 18a75f2

Please sign in to comment.