-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdocker-compose-prod.yml
84 lines (77 loc) · 2 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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
version: "3"
services:
web:
build: .
command: /code/start-web.sh
environment:
VIRTUAL_HOST: cfp.pygotham.org
VIRTUAL_PORT: 5000
LETSENCRYPT_HOST: cfp.pygotham.org
# TODO: this should really go to a group or ailias
LETSENCRYPT_EMAIL: [email protected]
links:
- db
volumes:
- ./yakbak.toml-prod:/code/yakbak.toml
restart: on-failure
grafana:
image: grafana/grafana
environment:
GF_SERVER_ROOT_URL: https://stats.cfp.pygotham.org
VIRTUAL_HOST: stats.cfp.pygotham.org
VIRTUAL_PORT: 3000
LETSENCRYPT_HOST: stats.cfp.pygotham.org
# TODO: this should really go to a group or ailias
LETSENCRYPT_EMAIL: [email protected]
links:
- db
volumes:
- grafana-data:/var/lib/grafana
restart: on-failure
db:
image: "postgres:10-alpine"
volumes:
- /home/pygotham/docker-volumes/db_data:/var/lib/postgresql/data
env_file:
# Don't store database secrets in source control
- ./database-secrets.env
restart: on-failure
nginx-proxy:
image: jwilder/nginx-proxy
container_name: nginx-proxy
labels:
- "com.github.jrcs.letsencrypt_nginx_proxy_companion.nginx_proxy"
ports:
- "80:80"
- "443:443"
restart: on-failure
volumes:
- /var/run/docker.sock:/tmp/docker.sock:ro
- certs:/etc/nginx/certs:ro
- conf:/etc/nginx/conf.d
- dhparam:/etc/nginx/dhparam
- html:/usr/share/nginx/html
- vhost:/etc/nginx/vhost.d
nginx-proxy-letsencrypt:
image: jrcs/letsencrypt-nginx-proxy-companion
container_name: nginx-proxy-letsencrypt
restart: on-failure
depends_on:
- nginx-proxy
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- certs:/etc/nginx/certs
- dhparam:/etc/nginx/dhparam:ro
- html:/usr/share/nginx/html
- vhost:/etc/nginx/vhost.d
volumes:
certs:
conf:
dhparam:
grafana-data:
html:
vhost:
networks:
default:
external:
name: nginx-proxy