File size: 539 Bytes
573da23
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
# Use the official Python image
FROM python:3.11-slim

# Set the working directory to /code
WORKDIR /code

# Copy the requirements file and install dependencies
COPY ./requirements.txt /code/requirements.txt
RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt

# Copy all the project files into the Docker container
COPY . .

# Expose port 7860 (Hugging Face Spaces requires apps to run on port 7860)
EXPOSE 7860

# Run the Flask app on port 7860
CMD ["flask", "--app", "app/app.py", "run", "--host=0.0.0.0", "--port=7860"]