forked from somanyWays/dev-tests
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.dev.yml
116 lines (104 loc) · 2.65 KB
/
docker-compose.dev.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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
version: "3.8"
services:
nginx:
image: nginx:1.25.3-alpine3.18
container_name: nginx
ports:
- "80:80"
- "443:443"
stop_grace_period: 0.1s
volumes:
- ./nginx/nginx.dev.conf:/etc/nginx/nginx.conf
- nginx:/var/log/nginx
networks:
- public
logging:
driver: none
deploy:
restart_policy:
condition: on-failure
delay: 5s
resources:
limits:
cpus: "0.5"
memory: 500M
reservations:
cpus: "0.1"
memory: 250M
placement:
constraints:
- node.role == manage
nestjs:
build:
dockerfile: dockerfile.dev
context: NestJS
ports:
- "3000:3000"
stop_grace_period: 0.1s
volumes:
- ./NestJS:/home/node
- /home/node/node_modules
depends_on:
- postgres
networks:
- public
- private
environment:
- ENV=dev
- POSTGRES_PASSWORD=pass
- POSTGRES_USER=root
- POSTGRES_DB=devtest
- POSTGRES_HOST=postgres
- POSTGRES_PORT=5432
angular:
build:
dockerfile: dockerfile.dev
context: Angular
ports:
- "4200:4200"
stop_grace_period: 0.1s
volumes:
- ./Angular:/home/node
- /home/node/node_modules
networks:
- public
postgres:
image: postgres:16.2-alpine3.19
ports:
- "5432:5432"
environment:
- POSTGRES_PASSWORD=pass
- POSTGRES_USER=root
- POSTGRES_DB=devtest
volumes:
- postgres:/var/lib/postgresql/data
networks:
- private
pgadmin:
image: dpage/pgadmin4:latest
ports:
- "3366:3366"
environment:
- PGADMIN_DEFAULT_EMAIL=trystansarrade@gmail.com
- PGADMIN_DEFAULT_PASSWORD=root
- PGADMIN_LISTEN_ADDRESS=0.0.0.0
- PGADMIN_LISTEN_PORT=3366
# Suppress Pgadmin logs
- GUNICORN_ACCESS_LOGFILE=/dev/null
- PGADMIN_CONFIG_CONSOLE_LOG_LEVEL=100
logging:
driver: none
volumes:
- pgadmin:/var/lib/pgadmin
networks:
- private
- public
volumes:
server:
nginx:
client:
postgres:
pgadmin:
networks:
public:
private: