-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.prod.yml
More file actions
32 lines (32 loc) · 910 Bytes
/
Copy pathdocker-compose.prod.yml
File metadata and controls
32 lines (32 loc) · 910 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
version: '3'
services:
nginx:
image: docker-tutorial/nginx_front
build:
context: ./
dockerfile: deploy/nginx.dockerfile
ports:
- "80:80"
depends_on:
- web # not optional, nginx crashes if it does not find web. It checks hostname in the startup phase.
# Fix this: https://sandro-keil.de/blog/2017/07/24/let-nginx-start-if-upstream-host-is-unavailable-or-down/
logging: &logging
driver: "json-file"
options:
# Rotate the files when they reach max-size.
max-size: "200k"
max-file: "10"
restart: always
web:
command: uwsgi --ini /app/uwsgi.ini
environment:
- QUIZ_ENV=production
logging:
<<: *logging
restart: always
db:
logging:
<<: *logging
restart: always
volumes:
- /quizdata:/var/lib/postgresql/data