-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.prod.yaml
More file actions
69 lines (63 loc) · 1.37 KB
/
docker-compose.prod.yaml
File metadata and controls
69 lines (63 loc) · 1.37 KB
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
version: '3.7'
services:
certbot:
container_name: certbot
build:
context: ./certbot
volumes:
- ./certbot/www:/var/www/certbot
- ./certbot/conf:/etc/letsencrypt
environment:
- CERTBOT_EMAIL=${CERTBOT_EMAIL}
- CERTBOT_DOMAIN=${CERTBOT_DOMAIN}
nginx:
image: nginx:latest
container_name: nginx-proxy
ports:
- '80:80'
- '443:443'
volumes:
- ./etc/nginx/conf.d:/etc/nginx
#읽기전용 : ro
- ./certbot/conf:/etc/letsencrypt:ro
- ./certbot/www:/var/www/certbot
depends_on:
- nestjs-server
networks:
- backend
restart: always
nestjs-server:
build:
context: ./
dockerfile: dockerfile.prod
container_name: nestjs-server
# ports:
# - '3000:3000'
networks:
- backend
environment:
- NODE_ENV=production
- MYSQL_DATABASE_SYNCHRONIZE=false
- PORT=20001
depends_on:
- mysql-server
restart: always
env_file:
- .env
mysql-server:
image: mysql:latest
container_name: mysql-server
environment:
MYSQL_ROOT_PASSWORD: ${DB_ROOT_PW}
MYSQL_DATABASE: ${DB_NAME}
MYSQL_USER: ${DB_USER}
MYSQL_PASSWORD: ${DB_PASSWORD}
# ports:
# - '3306:3306'
volumes:
- ./mysql_data:/var/lib/mysql
networks:
- backend
networks:
backend:
driver: bridge