forked from eugene-khyst/letsencrypt-docker-compose
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
51 lines (47 loc) · 1.27 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
version: "2"
services:
nginx:
build: ./nginx
image: devcomanda/nginx
env_file:
- ./config.env
volumes:
- devcomanda_nginx_ssl:/etc/nginx/ssl
- devcomanda_certbot_certs:/etc/letsencrypt
- test1_devcomanda_com_certbot:/var/www/certbot/test1.devcomanda.com
- test2_devcomanda_com_certbot:/var/www/certbot/test2.devcomanda.com
- ./html:/var/www/html/test1.devcomanda.com
- ./html:/var/www/html/test2.devcomanda.com
ports:
- "80:80"
- "443:443"
restart: always
certbot:
build: ./certbot
image: devcomanda/certbot
env_file:
- ./config.env
volumes:
- devcomanda_certbot_certs:/etc/letsencrypt
- test1_devcomanda_com_certbot:/var/www/certbot/test1.devcomanda.com
- test2_devcomanda_com_certbot:/var/www/certbot/test2.devcomanda.com
depends_on:
- nginx
cron:
build: ./cron
image: devcomanda/cron
environment:
COMPOSE_PROJECT_NAME: "${COMPOSE_PROJECT_NAME}"
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ./:/workdir:ro
depends_on:
- nginx
- certbot
volumes:
devcomanda_nginx_ssl:
external: true
devcomanda_certbot_certs:
external: true
test1_devcomanda_com_certbot:
test2_devcomanda_com_certbot: