22 lines
480 B
Docker
22 lines
480 B
Docker
FROM python:3.11-slim
|
|
|
|
WORKDIR /app
|
|
|
|
# Instalar dependencias del sistema necesarias para dateparser
|
|
RUN apt-get update && apt-get install -y \
|
|
gcc \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
# Copiar e instalar dependencias Python
|
|
COPY requirements.txt .
|
|
RUN pip install --no-cache-dir -r requirements.txt
|
|
|
|
# Copiar código fuente
|
|
COPY src/ ./src/
|
|
|
|
# Puerto de la aplicación
|
|
EXPOSE 8002
|
|
|
|
# Comando de arranque
|
|
CMD ["uvicorn", "src.main:app", "--host", "0.0.0.0", "--port", "8002"]
|