File size: 668 Bytes
7c89a70
21bcd44
b65b78e
7c89a70
b65b78e
 
7c89a70
21bcd44
b63ab49
 
b65b78e
7c89a70
21bcd44
 
7c89a70
21bcd44
b65b78e
7c89a70
21bcd44
b65b78e
7c89a70
b65b78e
 
7c89a70
21bcd44
 
b65b78e
7c89a70
21bcd44
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# Use Python 3.10 slim as base image
FROM python:3.10-slim

# Set working directory
WORKDIR /app

# Set environment variables
ENV PYTHONUNBUFFERED=1 \
    PYTHONDONTWRITEBYTECODE=1 \
    GEMINI_API_KEY=""

# Copy dependency files
COPY requirements.txt .

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

# Copy source code
COPY src/ ./src/

# Expose Streamlit port
EXPOSE 8501

# Set up health check
HEALTHCHECK --interval=30s --timeout=30s --start-period=5s --retries=3 \
    CMD curl -f http://localhost:8501/_stcore/health || exit 1

# Start command
CMD ["streamlit", "run", "src/app.py", "--server.port=8501", "--server.address=0.0.0.0"]