Skip to content

Instantly share code, notes, and snippets.

@raykipkorir
Last active March 13, 2025 00:09
Show Gist options
  • Save raykipkorir/18a4f3eec06a48214cc9c3aa274ffe57 to your computer and use it in GitHub Desktop.
Save raykipkorir/18a4f3eec06a48214cc9c3aa274ffe57 to your computer and use it in GitHub Desktop.
Dockerfile for Django app
FROM python:3.11.4-slim-bullseye
WORKDIR /app
ENV PYTHONUNBUFFERED 1
ENV PYTHONDONTWRITEBYTECODE 1
# install system dependencies
RUN apt-get update
# install dependencies
RUN pip install --upgrade pip
COPY ./requirements.txt /app/
RUN pip install -r requirements.txt
COPY . /app
ENTRYPOINT [ "gunicorn", "core.wsgi", "-b", "0.0.0.0:8000"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment