forked from project-kessel/inventory-api
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yaml
57 lines (54 loc) · 1.21 KB
/
docker-compose.yaml
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
services:
inventory-api:
depends_on:
- invdatabase
- invmigrate
environment:
INVENTORY_API_CONFIG: /inventory-api-compose.yaml
build:
dockerfile: Dockerfile
args:
VERSION: dev
volumes:
- ./inventory-api-compose.yaml:/inventory-api-compose.yaml:ro,z
- ./config/psks.yaml:/psks.yaml:ro,z
command: ["serve"]
restart: "always"
ports:
- "8081:8081"
- "9081:9081"
networks:
- kessel
invmigrate:
environment:
INVENTORY_API_CONFIG: /inventory-api-compose.yaml
build:
dockerfile: Dockerfile
args:
VERSION: dev
volumes:
- ./inventory-api-compose.yaml:/inventory-api-compose.yaml:ro,z
command: ["migrate"]
restart: "on-failure"
depends_on:
- invdatabase
networks:
- kessel
invdatabase:
image: "postgres"
command: ["-p", "5433","-c", "track_commit_timestamp=on"]
hostname: invdatabase
expose:
- "5433"
ports:
- "5433:5433"
environment:
- "POSTGRES_PASSWORD=${POSTGRES_PASSWORD}"
- "POSTGRES_DB=${POSTGRES_DBNAME}"
- "PGPORT=5433"
networks:
- kessel
networks:
kessel:
name: kessel
external: true