-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
53 lines (49 loc) · 1.33 KB
/
docker-compose.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
version: '3.7'
services:
nginx-proxy:
image: jwilder/nginx-proxy
container_name: nginx-proxy
restart: always
volumes:
- './logs/nginx:/var/log/nginx'
- 'certificates:/etc/nginx/certs:ro'
- 'vhosts:/etc/nginx/vhost.d'
- 'htmls:/usr/share/nginx/html'
- '/var/run/docker.sock:/tmp/docker.sock:ro'
environment:
- DEFAULT_HOST=${DEFAULT_HOST}
# - HTTPS_METHOD=noredirect
ports:
- "80:80"
- "443:443"
networks:
- nginx-proxy
labels:
# This is probably not needed anymore, need to check latest version of jwilder/nginx-proxy image source
- com.github.jrcs.letsencrypt_nginx_proxy_companion.nginx_proxy
nginx-letsencrypt:
image: jrcs/letsencrypt-nginx-proxy-companion
container_name: nginx-letsencrypt
restart: always
volumes:
- './certificates:/etc/nginx/certs'
- './certs:/etc/nginx/certs'
- 'certificates:/etc/nginx/certs:rw'
- 'vhosts:/etc/nginx/vhost.d'
- 'htmls:/usr/share/nginx/html'
- '/var/run/docker.sock:/var/run/docker.sock:ro'
environment:
NGINX_PROXY_CONTAINER: nginx-proxy
# DEBUG: 'true'
networks:
- nginx-proxy
networks:
nginx-proxy:
name: nginx-proxy
volumes:
certificates:
name: certificates
vhosts:
name: vhosts
htmls:
name: htmls