-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yaml
71 lines (67 loc) · 1.7 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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
services:
app:
depends_on:
- postgres
build:
context: ./
dockerfile: ./Dockerfile
target: develop
# Use the following to test performance
# target: test
volumes:
- .:/opt/blackledger
ports:
- "8000:8000"
environment:
DEBUG: "True"
AUTH_DISABLED: "True"
AUTH_JWKS_URL: http://keycloak:8001/realms/blackledger/protocol/openid-connect/certs
AUTH_ISSUER: http://localhost:8001/realms/blackledger
DATABASE_NAME: blackledger
DATABASE_URL: postgresql://postgres:password@postgres:5432/blackledger
DATABASE_DIALECT: psycopg
migrate:
depends_on:
- postgres
- app
image: blackledger-app
entrypoint: ["script/migrate.sh"]
volumes:
- .:/opt/blackledger
environment:
DATABASE_URL: postgresql://postgres:password@postgres:5432/blackledger
DATABASE_DIALECT: psycopg
postgres:
image: postgres:16
environment:
POSTGRES_DB: blackledger
POSTGRES_USER: postgres
POSTGRES_PASSWORD: password
POSTGRES_PORT: 5432
ports:
- "5432:5432"
volumes:
- pgdata:/var/lib/postgresql/data
- .:/opt/blackledger
keycloak:
image: quay.io/keycloak/keycloak:22.0.5
depends_on:
- postgres
environment:
KEYCLOAK_ADMIN: admin
KEYCLOAK_ADMIN_PASSWORD: admin
KC_DB: postgres
KC_DB_URL_HOST: postgres
KC_DB_URL_PORT: 5432
KC_DB_URL_DATABASE: keycloak
KC_DB_USERNAME: postgres
KC_DB_PASSWORD: password
KC_HTTP_PORT: "8001"
KC_HEALTH_ENABLED: true
KC_METRICS_ENABLED: true
command: ["start-dev"]
ports:
- "8001:8001"
restart: on-failure
volumes:
pgdata: