-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathdocker-compose.yml
85 lines (82 loc) · 2.07 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
85
---
version: "3.9"
x-common-variables: &common-variables
DATABASE_URI: postgresql://nwa:nwa@postgres/orchestrator-core
services:
#
# orchestrator-core-gui
#
gui:
image: "ghcr.io/workfloworchestrator/orchestrator-core-gui:latest"
env_file: orchestrator-core-gui.env
ports:
- "3000:8080"
depends_on:
orchestrator:
condition: service_started
#
# orchestrator-core
#
orchestrator:
image: "ghcr.io/workfloworchestrator/orchestrator-core:${CORE_VERSION:-latest}"
user: "${CI_USER:-}"
environment:
<<: *common-variables
ENABLE_WEBSOCKETS: "False"
OAUTH2_ACTIVE: False
ports:
- "8080:8080"
volumes:
- ${GITHUB_WORKSPACE:-.}:/home/orchestrator
depends_on:
db-upgrade-heads:
condition: service_completed_successfully
#
# orchestrator db upgrade heads
#
db-upgrade-heads:
image: "ghcr.io/workfloworchestrator/orchestrator-core:${CORE_VERSION:-latest}"
command: ["python", "main.py", "db", "upgrade", "heads"]
user: "${CI_USER:-}"
environment:
<<: *common-variables
volumes:
- ${GITHUB_WORKSPACE:-.}:/home/orchestrator
depends_on:
db-init:
condition: service_completed_successfully
#
# orchestrator db init
#
db-init:
image: "ghcr.io/workfloworchestrator/orchestrator-core:${CORE_VERSION:-latest}"
command: ["sh", "-c", "test -d migrations || python main.py db init"]
user: "${CI_USER:-}"
environment:
<<: *common-variables
volumes:
- ${GITHUB_WORKSPACE:-.}:/home/orchestrator
depends_on:
postgres:
condition: service_healthy
#
# postgres
#
postgres:
image: 'postgres:13'
ports:
- "5432:5432"
environment:
POSTGRES_USER: nwa
POSTGRES_PASSWORD: nwa
POSTGRES_DB: orchestrator-core
volumes:
- db-data:/var/lib/postgresql/data/
healthcheck:
test: ["CMD", "pg_isready", "--username", "nwa", "--dbname", "orchestrator-core"]
interval: "3s"
timeout: "2s"
retries: 20
start_period: "5s"
volumes:
db-data: