scanningspace / Dockerfile
classVerse's picture
Create Dockerfile
88ee540 verified
Raw History Blame Contribute Delete
479 Bytes
# Use an official lightweight Python image
FROM python:3.10-slim
# Set the working directory inside the container
WORKDIR /app
# Copy the requirements file and install dependencies
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Copy the rest of your application code
COPY . .
# Hugging Face requires apps to listen on port 7860
EXPOSE 7860
# Command to run the FastAPI server
CMD ["uvicorn", "server:app", "--host", "0.0.0.0", "--port", "7860"]