Agregar docker-compose y Dockerfiles para EasyPanel

This commit is contained in:
Panchito
2026-07-22 10:24:58 -05:00
parent 9cc2d28b9a
commit 122dee2d90
6 changed files with 120 additions and 0 deletions

27
backend/Dockerfile Normal file
View File

@@ -0,0 +1,27 @@
FROM python:3.11-slim
WORKDIR /app
# Dependencias del sistema necesarias para pyodbc (SQL Server) y psycopg2
RUN apt-get update && apt-get install -y --no-install-recommends \
gcc \
g++ \
unixodbc \
unixodbc-dev \
curl \
gnupg \
&& curl https://packages.microsoft.com/keys/microsoft.asc | apt-key add - \
&& curl https://packages.microsoft.com/config/debian/12/prod.list > /etc/apt/sources.list.d/mssql-release.list \
&& apt-get update \
&& ACCEPT_EULA=Y apt-get install -y --no-install-recommends msodbcsql18 \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY . .
EXPOSE 8001
CMD ["python", "main.py"]