JohnLicode
Add Dockerfile forcing Python 3.12 to fix Jinja2 caching incompatibility with Python 3.13
d7d316b
raw
history blame contribute delete
466 Bytes
# Use Python 3.12 slim base image to avoid Python 3.13 incompatibilities
FROM python:3.12-slim
# Set working directory
WORKDIR /app
# Copy application files
COPY requirements.txt .
COPY app.py .
# Install Python dependencies
RUN pip install --no-cache-dir -r requirements.txt
# Expose port for Gradio
EXPOSE 7860
# Set environment variables for Gradio
ENV GRADIO_SERVER_NAME="0.0.0.0"
ENV GRADIO_SERVER_PORT=7860
# Run the application
CMD ["python", "app.py"]