Guest User

Untitled

a guest
Jan 24th, 2019
138
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.90 KB | None | 0 0
  1. version: '3'
  2. networks:
  3. bridge:
  4. driver: bridge
  5. services:
  6. db:
  7. image: postgres:10
  8. container_name: myapp-db
  9. volumes:
  10. - ./postgres_data:/var/lib/postgresql/data/
  11. ports:
  12. - "5432:5432"
  13. environment:
  14. POSTGRES_DB: actionability-master
  15. POSTGRES_PASSWORD: postgres
  16. POSTGRES_USER: postgres
  17. networks:
  18. - bridge
  19.  
  20.  
  21. web:
  22. restart: unless-stopped
  23. container_name: myapp-web
  24. build: .
  25. command: /start_gunicorn.sh
  26. ports:
  27. - "8080:8080"
  28. environment:
  29. PRODUCTION: 'true'
  30. networks:
  31. - bridge
  32.  
  33. DATABASES = {
  34. 'default': {
  35. 'ENGINE': 'django.db.backends.postgresql_psycopg2',
  36. 'NAME': INSTANCE_NAME,
  37. 'USER': 'postgres',
  38. 'PASSWORD': 'postgres',
  39. 'HOST': 'db',
  40. 'PORT': '5432'
  41. },
  42.  
  43. }
  44.  
  45. RUN python manage.py makemigrations myapp
  46. RUN python manage.py migrate
  47.  
  48. expose:
  49. - "5432"
Add Comment
Please, Sign In to add comment