File size: 625 Bytes
e196d75
 
 
 
 
 
4a3cea3
 
 
e196d75
 
 
 
4a3cea3
e196d75
 
4a3cea3
 
e196d75
 
4a3cea3
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# Use official Python image
FROM python:3.10

# Set working directory
WORKDIR /app

# Create .streamlit folder with permissions
RUN mkdir -p /app/.streamlit && chmod -R 777 /app/.streamlit

# Copy requirements and install dependencies
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt

# Copy all project files
COPY . .

# Expose ports
EXPOSE 8000
EXPOSE 7860

# Run both FastAPI and Streamlit properly
CMD ["bash", "-c", "uvicorn backend.main:app --host 0.0.0.0 --port 8000 & streamlit run app.py --server.port 7860 --server.address 0.0.0.0 --server.headless true --browser.gatherUsageStats false"]