Spaces:
Sleeping
Sleeping
File size: 557 Bytes
02b2ce1 e92d385 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
FROM python:3.11
WORKDIR /app
COPY . /app
RUN pip install --upgrade pip
RUN pip install -r requirements.txt
EXPOSE 7860
# Ensure logs directory exists
RUN mkdir -p /app/logs && chmod -R 777 /app/logs
# Install tmux to run multiple processes
RUN apt-get update && apt-get install -y tmux
# Set Python path
ENV PYTHONPATH="/app/src"
# Start FastAPI & Streamlit together using tmux
CMD ["sh", "-c", "fastapi dev src/backend/main.py --host 0.0.0.0 --port 8000 & sleep 5 && streamlit run src/frontend/app.py --server.port 7860 --server.address 0.0.0.0"] |