-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
84 lines (77 loc) · 1.86 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
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
version: '3.6'
services:
db:
image: postgres:latest
env_file:
- ./server/postgres.env
ports:
- 5432:5432
volumes:
- postgres_data:/var/lib/postgresql/data
mem_limit: 100m
client:
stdin_open: true
build:
dockerfile: Dockerfile
context: ./client
env_file:
- ./client/.env
volumes:
- /app/node_modules
- ./client:/app
mem_limit: 100M
api:
build:
dockerfile: Dockerfile
context: ./server
env_file:
- ./server/.env
- ./server/redis.env
- ./server/postgres.env
depends_on:
- db
- redis
ports:
- 4000:4000
volumes:
- /app/node_modules
- ./server:/app
mem_limit: 756m
mem_reservation: 256M
nginx:
depends_on:
- api
- client
restart: always
build:
dockerfile: Dockerfile.dev
context: ./nginx
ports:
- '80:80'
mem_limit: 156m
redis:
image: redis:6.2-alpine
env_file:
- ./server/redis.env
command: /bin/sh -c "redis-server --requirepass $$REDIS_PASSWORD"
restart: always
volumes:
- redis:/var/lib/redis/data
ports:
- 6379:6379
mem_limit: 100m
# pgadmin:
# image: dpage/pgadmin4
# container_name: pgadmin4_container
# restart: always
# ports:
# - '5050:80'
# environment:
# PGADMIN_DEFAULT_EMAIL: EMAIL
# PGADMIN_DEFAULT_PASSWORD: PASSWORD
# volumes:
# - pgadmin-data:/var/lib/pgadmin
volumes:
postgres_data:
redis:
# pgadmin-data: