wearon / Dockerfile
Bhushan26's picture
Update Dockerfile
09392c6 verified
raw
history blame contribute delete
604 Bytes
# Dockerfile
# Use a base image appropriate for your application
FROM tiangolo/uvicorn-gunicorn-fastapi:python3.9
# Set working directory
WORKDIR /app
# Copy requirements.txt first for caching dependencies
COPY ./requirements.txt .
# Install dependencies
RUN pip install -r requirements.txt
# Copy the rest of the application code
COPY . .
# Create necessary directories and set permissions
RUN mkdir -p /app/static/uploads /app/static/results \
&& chmod -R 777 /app/static/uploads /app/static/results
# Start the application
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]