Skip to content

Instantly share code, notes, and snippets.

@parsa-asgari
Created February 13, 2022 11:46
Show Gist options
  • Save parsa-asgari/16570602424d356255862cb55193aa6a to your computer and use it in GitHub Desktop.
Save parsa-asgari/16570602424d356255862cb55193aa6a to your computer and use it in GitHub Desktop.
sample dockerfile for django api
FROM ubuntu:latest
RUN apt-get update && apt-get install -y \
git \
python3 \
python3-pip
RUN pip3 install django djangorestframework tzdata
ENV LC_ALL C.UTF-8
ENV LANG C.UTF-8
WORKDIR /app
COPY . /app
EXPOSE 8000
ENTRYPOINT ["python3"]
CMD ["manage.py", "runserver","0.0.0.0:8000"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment