-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
109 lines (104 loc) · 4.66 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
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
version: "3.8"
services:
spiffworkflow-frontend:
container_name: spiffworkflow-frontend
image: ghcr.io/sartography/spiffworkflow-frontend:main-latest
depends_on:
spiffworkflow-backend:
condition: service_healthy
environment:
APPLICATION_ROOT: "/"
PORT0: "${SPIFFWORKFLOW_FRONTEND_PORT:-3001}"
SPIFFWORKFLOW_FRONTEND_RUNTIME_CONFIG_APP_ROUTING_STRATEGY: path_based
SPIFFWORKFLOW_HOST: "${SPIFFWORKFLOW_HOST:-localhost}"
SPIFFWORKFLOW_FRONTEND_RUNTIME_CONFIG_BACKEND_BASE_URL: "${SPIFFWORKFLOW_PROTOCOL:-http}://${SPIFFWORKFLOW_HOST:-localhost}:${SPIFFWORKFLOW_PORT:-3003}/api"
# ports:
# - "${SPIFFWORKFLOW_FRONTEND_PORT:-3001}:${SPIFFWORKFLOW_FRONTEND_PORT:-3001}/tcp"
spiffworkflow-backend:
depends_on:
spiffdb:
condition: service_healthy
container_name: spiffworkflow-backend
image: ghcr.io/sartography/spiffworkflow-backend:main-latest
user: ${RUN_AS:-0:0}
environment:
SPIFFWORKFLOW_BACKEND_ENV: "local_docker"
FLASK_DEBUG: "0"
FLASK_SESSION_SECRET_KEY: "${FLASK_SESSION_SECRET_KEY:-super_secret_key}"
SPIFFWORKFLOW_BACKEND_URL: "${SPIFFWORKFLOW_PROTOCOL:-http}://${SPIFFWORKFLOW_HOST:-localhost}:${SPIFFWORKFLOW_PORT:-3003}/api"
SPIFFWORKFLOW_BACKEND_BPMN_SPEC_ABSOLUTE_DIR: "/app/process_models"
SPIFFWORKFLOW_BACKEND_CONNECTOR_PROXY_URL: "${SPIFFWORKFLOW_BACKEND_CONNECTOR_PROXY_URL:-http://spiffworkflow-connector:3004}"
SPIFFWORKFLOW_BACKEND_DATABASE_TYPE: "postgres"
SPIFFWORKFLOW_BACKEND_DATABASE_URI: "postgresql://spiffuser:spiffpass@spiffdb:5432/spiffworkflow"
SPIFFWORKFLOW_BACKEND_LOAD_FIXTURE_DATA: "false"
SPIFFWORKFLOW_BACKEND_LOG_LEVEL: "DEBUG"
SPIFFWORKFLOW_BACKEND_OPEN_ID_CLIENT_ID: "spiffworkflow-backend"
SPIFFWORKFLOW_BACKEND_OPEN_ID_CLIENT_SECRET_KEY: "my_open_id_secret_key"
SPIFFWORKFLOW_BACKEND_PORT: "3000"
SPIFFWORKFLOW_BACKEND_OPEN_ID_SERVER_URL: "${SPIFFWORKFLOW_PROTOCOL:-http}://${SPIFFWORKFLOW_HOST:-localhost}:${SPIFFWORKFLOW_PORT:-3003}/api/openid"
SPIFFWORKFLOW_BACKEND_PERMISSIONS_FILE_ABSOLUTE_PATH: "/app/permissions/example.yml"
SPIFFWORKFLOW_BACKEND_RUN_BACKGROUND_SCHEDULER_IN_CREATE_APP: "true"
SPIFFWORKFLOW_BACKEND_UPGRADE_DB: "true"
SPIFFWORKFLOW_BACKEND_URL_FOR_FRONTEND: "${SPIFFWORKFLOW_PROTOCOL:-http}://${SPIFFWORKFLOW_HOST:-localhost}:${SPIFFWORKFLOW_PORT:-3003}"
SPIFFWORKFLOW_BACKEND_OPEN_ID_SERVER_INTERNAL_URL: http://spiffworkflow-backend:3000/api/openid
SPIFFWORKFLOW_BACKEND_OPEN_ID_INTERNAL_URL_IS_VALID_ISSUER: true
SPIFFWORKFLOW_BACKEND_WSGI_PATH_PREFIX: /api
SPIFFWORKFLOW_BACKEND_USE_WERKZEUG_MIDDLEWARE_PROXY_FIX: true
# ports:
# - "${SPIFFWORKFLOW_BACKEND_PORT:-3000}:${SPIFFWORKFLOW_BACKEND_PORT:-3000}/tcp"
volumes:
- ./process_models:/app/process_models
- ./configs/permissions:/app/permissions
- spiffworkflow_backend_db:/app/db_volume
healthcheck:
test: "curl http://localhost:${SPIFFWORKFLOW_BACKEND_PORT:-3000}/api/v1.0/status --fail"
interval: 10s
timeout: 5s
retries: 20
spiffdb:
image: postgres:latest
environment:
POSTGRES_USER: spiffuser
POSTGRES_PASSWORD: spiffpass
POSTGRES_DB: spiffworkflow
# ports:
# - "3005:5432"
volumes:
- spiffworkflow_backend_db:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U spiffuser -d spiffworkflow"]
interval: 10s
timeout: 5s
retries: 5
spiffworkflow-connector:
container_name: spiffworkflow-connector
image: ghcr.io/sartography/connector-proxy-demo:latest
environment:
FLASK_ENV: "${FLASK_ENV:-development}"
FLASK_DEBUG: "0"
FLASK_SESSION_SECRET_KEY: "${FLASK_SESSION_SECRET_KEY:-super_secret_key}"
CONNECTOR_PROXY_PORT: "${SPIFF_CONNECTOR_PORT:-3004}"
# ports:
# - "${SPIFF_CONNECTOR_PORT:-3004}:${SPIFF_CONNECTOR_PORT:-3004}/tcp"
healthcheck:
test: "curl http://localhost:${SPIFF_CONNECTOR_PORT:-3004}/liveness --fail"
interval: 10s
timeout: 5s
retries: 20
nginx-proxy:
container_name: proxy
image: nginx:latest
ports:
- "${SPIFFWORKFLOW_PORT:-3003}:${SPIFFWORKFLOW_PORT:-3003}"
volumes:
# By default, an entrypoint function reads template files in /etc/nginx/templates/*.template and outputs the result of executing envsubst to /etc/nginx/conf.d.
- ./templates:/etc/nginx/templates
depends_on:
- spiffworkflow-frontend
- spiffworkflow-backend
environment:
NGINX_SERVER_NAME: "${SPIFFWORKFLOW_HOST:-localhost}"
NGINX_PORT: "${SPIFFWORKFLOW_PORT:-3003}"
volumes:
spiffworkflow_backend_db:
driver: local