generated from C4T-BuT-S4D/ad-boilerplate
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
49 lines (46 loc) · 984 Bytes
/
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
version: '2.4'
services:
db:
image: postgres:14-alpine
restart: unless-stopped
environment:
POSTGRES_USER: user
POSTGRES_PASSWORD: password
POSTGRES_DB: test
volumes:
- db_data:/var/lib/postgresql/data
- ./conf/pg:/docker-entrypoint-initdb.d
app:
build: .
restart: unless-stopped
ports:
- "4222:22"
pids_limit: 1024
mem_limit: 1024m
cpus: 2
depends_on:
- db
volumes:
- etc:/etc # Persist the users files.
- users_data:/users # Persist users data.
environment:
- PG.USER=user
- PG.PASSWORD=password
- PG.HOST=db
- PG.PORT=5432
- PG.DBNAME=test
- PG.POOL.MAX_SIZE=128
nginx:
image: nginx:1.18.0-alpine
restart: unless-stopped
volumes:
- ./conf/nginx/app.conf:/etc/nginx/conf.d/default.conf:ro
- ./front:/front:ro
depends_on:
- app
ports:
- "8080:80"
volumes:
users_data:
etc:
db_data: