mirror of
https://huggingface.co/spaces/Catapang1989/movie-hub
synced 2026-04-17 16:11:45 +00:00
Upload 3 files
This commit is contained in:
23
Dockerfile
Normal file
23
Dockerfile
Normal file
@@ -0,0 +1,23 @@
|
||||
# Use official Python lightweight image
|
||||
FROM python:3.10-slim
|
||||
|
||||
# Set the working directory
|
||||
WORKDIR /app
|
||||
|
||||
# Copy requirements and install them
|
||||
COPY requirements.txt .
|
||||
RUN pip install --no-cache-dir -r requirements.txt
|
||||
|
||||
# Copy the rest of the application files
|
||||
COPY . .
|
||||
|
||||
# Set up a non-root user (Required by Hugging Face Spaces)
|
||||
RUN useradd -m -u 1000 user
|
||||
RUN chown -R user:user /app
|
||||
USER user
|
||||
|
||||
# Expose the default Hugging Face Space port
|
||||
EXPOSE 7860
|
||||
|
||||
# Command to run the FastAPI application
|
||||
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]
|
||||
Reference in New Issue
Block a user