-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
40 lines (40 loc) · 920 Bytes
/
docker-compose.yml
File metadata and controls
40 lines (40 loc) · 920 Bytes
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
version: '3.4'
services:
server:
build:
context: .
image: server
command: |
-config /config
-appname p2pdserver
-e integration
-migrate
environment:
- P2PDSERVER_DATABASE_HOST=db
restart: always
depends_on:
- db
ports:
- 8080:8080
volumes:
- ./test/config:/config
db:
image: "postgres:12.2"
command: |
-c log_statement=all
-c ssl=on
-c ssl_cert_file=/var/lib/postgresql/db.crt
-c ssl_key_file=/var/lib/postgresql/db.key
restart: always
ports:
- 5432:5432
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=1234
- POSTGRES_DB=db
volumes:
- db-data:/var/lib/postgresql/data/ # persist data even if container shuts down
- ./certs/db.crt:/var/lib/postgresql/db.crt
- ./certs/db.key:/var/lib/postgresql/db.key
volumes:
db-data: