Spaces:
Sleeping
Sleeping
# Base image | |
FROM python:3.10-slim | |
# Install necessary dependencies | |
RUN apt-get update \ | |
&& apt-get install -y openssl \ | |
&& apt-get clean \ | |
&& rm -rf /var/lib/apt/lists/* /var/cache/apt/archives/* | |
# Set working directory | |
WORKDIR /app | |
# Copy the FastAPI application code to the container | |
COPY requirements.txt . | |
# Install Python dependencies | |
RUN pip install -r requirements.txt | |
COPY . . | |
# Expose the HTTPS port | |
EXPOSE 443 5080 | |
# Command to run FastAPI with SSL | |
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "5080"] |