-
Notifications
You must be signed in to change notification settings - Fork 6
/
docker-compose.prod.yml
68 lines (63 loc) · 1.31 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
version: '3.9'
services:
server:
restart: always
image: prakticum-server
build:
context: .
dockerfile: Dockerfile.server
args:
SERVER_PORT: ${SERVER_PORT}
env_file:
- .env
environment:
POSTGRES_HOST: postgres
MONGO_HOST: mongo
LETSENCRYPT_HOST: ${APP_HOSTNAME}
VIRTUAL_HOST: ${APP_HOSTNAME}
VIRTUAL_PORT: ${SERVER_PORT}
depends_on:
- postgres
- mongo
networks:
- mynet
nginx-proxy:
image: nginxproxy/nginx-proxy
container_name: nginx-proxy
restart: always
ports:
- 80:80
- 443:443
volumes:
- conf:/etc/nginx/conf.d
- vhost:/etc/nginx/vhost.d
- html:/usr/share/nginx/html
- certs:/etc/nginx/certs:ro
- /var/run/docker.sock:/tmp/docker.sock:ro
networks:
- mynet
acme-companion:
image: nginxproxy/acme-companion
container_name: nginx-proxy-acme
restart: always
environment:
- DEFAULT_EMAIL=mail@${APP_HOSTNAME}
volumes_from:
- nginx-proxy
volumes:
- certs:/etc/nginx/certs:rw
- acme:/etc/acme.sh
- /var/run/docker.sock:/var/run/docker.sock:ro
volumes:
pg-data:
mongodb-data:
volumes:
conf:
vhost:
html:
certs:
acme:
networks:
mynet:
name: tanchiki_default
external: true