-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
47 lines (46 loc) · 1.28 KB
/
docker-compose.yml
File metadata and controls
47 lines (46 loc) · 1.28 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
services:
postgres:
image: postgres:15
container_name: starmap_postgres
environment:
POSTGRES_DB: starmap_development
POSTGRES_USER: postgres
POSTGRES_PASSWORD: password
ports:
- "5432:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
- ./db/init:/docker-entrypoint-initdb.d
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 10s
timeout: 5s
retries: 5
keycloak:
image: quay.io/keycloak/keycloak:26.0
container_name: starmap_keycloak
command: start-dev --import-realm
environment:
KC_HEALTH_ENABLED: "true"
KC_FRONTEND_URL: http://starmap.localhost:5101
KC_DB: postgres
KC_DB_URL: jdbc:postgresql://starmap_postgres:5432/keycloak
KC_DB_USERNAME: postgres
KC_DB_PASSWORD: password
KEYCLOAK_ADMIN: admin
KEYCLOAK_ADMIN_PASSWORD: admin
ports:
- "5101:8080"
volumes:
- ./docker/keycloak/realm-export.json:/opt/keycloak/data/import/realm-export.json
depends_on:
postgres:
condition: service_healthy
healthcheck:
test: ["CMD-SHELL", "curl -sf http://localhost:8080/health/ready || exit 1"]
interval: 15s
timeout: 5s
retries: 10
start_period: 30s
volumes:
postgres_data: