124-webapp/Dockerfile

28 lines
525 B
Text
Raw Normal View History

2025-09-11 16:01:32 +02:00
# Dockerfile
FROM python:3.12-slim
# Set environment variables
ENV PYTHONDONTWRITEBYTECODE 1
ENV PYTHONUNBUFFERED 1
# Set working directory
WORKDIR /cost-assistant
# Copy requirements first (for caching)
COPY requirements.txt .
# Install dependencies
RUN pip install --no-cache-dir -r requirements.txt
# Copy the project files
COPY . .
# Create upload folder
RUN mkdir -p data/uploads
# Expose port
EXPOSE 8000
# Run FastAPI with Uvicorn
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000", "--reload"]