Created
June 11, 2017 15:26
-
-
Save IlianIliev/0822de2b05a28c86bbecaeb7a26f8294 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Dockerfile | |
FROM python:3.5 | |
ENV PYTHONUNBUFFERED 1 | |
ADD . /<project> | |
WORKDIR /<project> | |
RUN pip install -r requirements.txt | |
# docker-compose.yml | |
version: '3' | |
services: | |
db: | |
container_name: <project>-db | |
image: postgres | |
api: | |
container_name: <project>-api | |
build: ./<project> | |
environment: | |
- DJANGO_SETTINGS_MODULE=<project>.settings.develop | |
volumes: | |
- ./<project>:/<project> | |
command: python manage.py runserver 0.0.0.0:8001 | |
ports: | |
- "8001:8001" | |
depends_on: | |
- db |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment