-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose-prod.yml
63 lines (62 loc) · 1.41 KB
/
docker-compose-prod.yml
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
# This is (mostly) just a copy of docker-compose.yml
# However, we there's a few changes to the `giz` service:
# * command is set to gunicorn
# * no debugging ports are exposed
# * DEBUG is not set, and PROD=True
# * the source code is not mounted, but rather added
services:
gitolite:
image: jgiannuzzi/gitolite
ports:
- 22:22
volumes:
- gitolite-sshkeys:/etc/ssh/keys
- gitolite-git:/var/lib/git
environment:
- SSH_KEY
postgres:
image: postgres:latest
restart: always
environment:
- POSTGRES_PASSWORD
- POSTGRES_DB: giz
volumes:
- /root/data:/var/lib/postgresql/data
redis:
image: redis:5
nginx:
build: services/nginx
volumes:
- static:/usr/share/www/static:ro
- /root/letsencrypt:/etc/letsencrypt
ports:
- 80:80
- 443:443
giz:
build: .
logging:
driver: "json-file"
options:
max-size: "10k"
max-file: "1"
environment:
- PROD=True
- GITOLITE_HOST=gitolite
- GITOLITE_PORT=22
- GITOLITE_KEY
- POSTGRES_PASSWORD
- SECRET_KEY
depends_on:
- nginx
- redis
- gitolite
- postgres
volumes:
- gitolite-sshkeys:/root/keys:ro
- gitolite-git:/usr/share/git:ro
- static:/usr/share/giz/static
command: gunicorn -c /usr/share/gunicorn-conf.py
volumes:
gitolite-sshkeys:
gitolite-git:
static: