KurdishTranslatorAPI / Dockerfile
gresqdf's picture
First commit
9ab1a01
raw
history blame
655 Bytes
# Use an official Python image as the base image
FROM python:3.8-slim
# Set the working directory inside the container
WORKDIR /app
# Install system dependencies
RUN apt-get update && apt-get install
# Install PyTorch
RUN pip install --upgrade pip
RUN pip install torch torchvision
# Install Hugging Face Transformers and other dependencies
RUN pip install transformers librosa deep-translator python-multipart fastapi uvicorn
# Copy the main script
COPY main.py .
# Expose the port the app runs on
EXPOSE 8000
# Set the default command to run your FastAPI app or any other server
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000"]