File size: 546 Bytes
5190454
f02148f
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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

# Set working directory
WORKDIR /code

# Copy requirements
COPY ./backend/requirements.txt /code/requirements.txt

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

# Create necessary directories
RUN mkdir -p /code/databases/csv /code/databases/schema /code/sample_data

# Copy the entire project
COPY . /code/

# Hugging Face Spaces run on port 7860 by default
ENV PORT=7860

# Run the FastAPI app with Uvicorn
CMD ["uvicorn", "backend.main:app", "--host", "0.0.0.0", "--port", "7860"]