-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.pro.yml
92 lines (84 loc) · 1.85 KB
/
docker-compose.pro.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
85
86
87
88
89
90
91
92
version: '3.9'
services:
api:
container_name: CHANGE_ME_api
build:
context: .
dockerfile: Dockerfile.pro
command: npm run start:dev
restart: always
ports:
- $API_PORT:$API_PORT
volumes:
- .:/home/app
env_file:
- ./.env
networks:
- nest_demo_network
db:
container_name: CHANGE_ME_db
image: mongo
restart: always
environment:
- MONGO_INITDB_ROOT_USERNAME
- MONGO_INITDB_ROOT_PASSWORD
- MONGO_INITDB_DATABASE
volumes:
- db:/data/db
networks:
- nest_demo_network
admin:
container_name: CHANGE_ME_db_admin
image: mongo-express
restart: always
ports:
- $ADMIN_PORT:8081
environment:
- ME_CONFIG_MONGODB_ADMINUSERNAME=$MONGO_INITDB_ROOT_USERNAME
- ME_CONFIG_MONGODB_ADMINPASSWORD=$MONGO_INITDB_ROOT_PASSWORD
- ME_CONFIG_MONGODB_URL=$MONGO_URI
- ME_CONFIG_SITE_BASEURL=/mongo-admin
depends_on:
- db
networks:
- nest_demo_network
files:
container_name: CHANGE_ME_db_file
image: nginx:alpine
restart: always
volumes:
- $FILE_ROOT:/usr/share/nginx/html
ports:
- $FILE_PORT:80
networks:
- nest_demo_network
redis:
container_name: CHANGE_ME_redis
image: redis
command: bash -c "redis-server --appendonly yes --requirepass $REDIS_PASSWORD"
restart: always
volumes:
- redis:/data/cache
networks:
- nest_demo_network
web-server:
container_name: CHANGE_ME_server
image: nginx:latest
restart: always
volumes:
- ./nginx/nginx.conf:/etc/nginx/nginx.conf
- ./nginx/ssl:/etc/nginx/ssl
expose:
- '443'
- '80'
ports:
- '5050:80/tcp'
- '5051:443/tcp'
networks:
- nest_demo_network
volumes:
redis:
db:
networks:
nest_demo_network:
external: true