ocr-api / Dockerfile
Sugamdeol's picture
Create Dockerfile
faf052d verified
raw
history blame
696 Bytes
# Dockerfile
# Use the official, full Python image for best compatibility
FROM python:3.11
# Set the working directory inside the container
WORKDIR /app
# Install system dependencies listed in packages.txt
COPY packages.txt .
RUN apt-get update && xargs -a packages.txt apt-get install -y --no-install-recommends && apt-get clean && rm -rf /var/lib/apt/lists/*
# Copy and install Python requirements
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Copy the rest of your application code
COPY . .
# Expose the port that the application will run on
EXPOSE 7860
# NO CMD OR ENTRYPOINT LINE HERE
# The Hugging Face platform will provide the command to run the app.