samrat-doi/LLM-Code-Deployment-Github
0
1# Use an official Python runtime as a parent image2# Using a stable version like 3.11 to avoid all compatibility issues3FROM python:3.11-slim4 5# Set the working directory in the container6WORKDIR /app7 8# Copy the requirements file into the container9COPY requirements.txt .10 11# Install any needed packages specified in requirements.txt12RUN pip install --no-cache-dir -r requirements.txt13 14# Copy the rest of the application code into the container15COPY . .16 17# Expose the port the app runs on18EXPOSE 786019 20# Command to run the application21# We use --host 0.0.0.0 to make it accessible from outside the container22CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]