Advertisement
Guest User

Untitled

a guest
May 1st, 2017
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 0.72 KB | None | 0 0
  1. data:
  2.   restart: always
  3.   image: busybox
  4.   volumes:
  5.    - ./db:/var/lib/postgresql
  6.   command: "true"
  7.  
  8. postgres:
  9.   restart: always
  10.   image: postgres:9.4
  11.   volumes_from:
  12.    - data
  13.   volumes:
  14.    - ./db_dump:/dumps
  15.   ports:
  16.    - "5432:5432"
  17.   environment:
  18.     POSTGRES_PASSWORD: postgres
  19.     POSTGRES_USER: postgres
  20.  
  21.  
  22. web:
  23.   restart: always
  24.   build: .
  25.   command: bash -c 'python manage.py migrate && python manage.py runserver 0.0.0.0:8001'
  26.   volumes:
  27.    - .:/project
  28.   ports:
  29.    - "8001:8001"
  30.   links:
  31.    - postgres
  32.   environment:
  33.     DJANGO_DEBUG: "True"
  34.  
  35.  
  36. nginx:
  37.   restart: always
  38.   build: ./nginx/
  39.   ports:
  40.    - "80:80"
  41.     - "443:443"
  42.   volumes_from:
  43.    - web
  44.   links:
  45.    - web
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement