-
Notifications
You must be signed in to change notification settings - Fork 14
Expand file tree
/
Copy pathdocker-compose-deploy.yaml
More file actions
67 lines (64 loc) · 2.19 KB
/
docker-compose-deploy.yaml
File metadata and controls
67 lines (64 loc) · 2.19 KB
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
## Deployment: Operaton (Spring Boot + Keycloak JWT) + Keycloak + Web Apps (nginx)
##
## Usage:
## docker compose -f docker-compose-deploy.yaml up --build
## podman compose -f docker-compose-deploy.yaml up --build
##
## Services:
## - web-apps: http://localhost:1111 (SPA + API proxy via nginx)
## - operaton: http://localhost:8084 (Operaton engine REST API)
## - keycloak: http://localhost:8888 (Keycloak admin console)
##
## Default credentials:
## Keycloak admin: admin / admin
## Operaton user: demo / demo (authenticated via Keycloak)
services:
operaton:
build:
context: ./operaton
dockerfile: Dockerfile
environment:
- KEYCLOAK_URL=http://keycloak:8080
- KEYCLOAK_REALM=operaton
- KEYCLOAK_CLIENT_ID=operaton-identity-service
- KEYCLOAK_CLIENT_SECRET=operaton-identity-secret
ports:
- "8084:8080"
restart: on-failure
depends_on:
keycloak:
condition: service_healthy
keycloak:
image: quay.io/keycloak/keycloak:26.0
environment:
- KC_BOOTSTRAP_ADMIN_USERNAME=admin
- KC_BOOTSTRAP_ADMIN_PASSWORD=admin
- KC_HEALTH_ENABLED=true
command: start-dev --import-realm
volumes:
- ./keycloak/operaton-realm.json:/opt/keycloak/data/import/operaton-realm.json:z
ports:
- "8888:8080"
healthcheck:
test: ["CMD-SHELL", "exec 3<>/dev/tcp/localhost/9000 && echo -e 'GET /health/ready HTTP/1.1\\r\\nHost: localhost\\r\\nConnection: close\\r\\n\\r\\n' >&3 && cat <&3 | grep -q '200 OK'"]
interval: 10s
timeout: 5s
retries: 15
start_period: 30s
web-apps:
build:
context: .
dockerfile: Dockerfile
environment:
- ASSET_DIR=/var/www/html
- APP_PREFIX=DOCKER_RUN_PLACEHOLDER_
- DOCKER_RUN_PLACEHOLDER_BACKEND=[{\\"name\\":\\"Operaton\\",\\"url\\":\\"http://localhost:1111\\"}]
- DOCKER_RUN_PLACEHOLDER_AUTH_MODE=oauth
- DOCKER_RUN_PLACEHOLDER_OAUTH_AUTHORITY=http://localhost:8888/realms/operaton
- DOCKER_RUN_PLACEHOLDER_OAUTH_CLIENT_ID=operaton-web-apps
- DOCKER_RUN_PLACEHOLDER_OAUTH_REDIRECT_URI=http://localhost:1111/
ports:
- "1111:80"
depends_on:
- operaton
- keycloak