-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose-ledger-dynamodb.yml
68 lines (63 loc) · 2.27 KB
/
docker-compose-ledger-dynamodb.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
include:
- ./docker-compose-ledger-common.yml
services:
dynamodb:
image: amazon/dynamodb-local:2.5.2
container_name: "dynamodb-1"
ports:
- "8000:8000"
networks:
- scalar-network
healthcheck:
test: ["CMD-SHELL", '[ "$(curl -s -o /dev/null -I -w ''%{http_code}'' http://localhost:8000)" == "400" ] || exit 1']
interval: 1s
timeout: 10s
retries: 60
start_period: 30s
scalardl-ledger-schema-loader:
image: ghcr.io/scalar-labs/scalardl-schema-loader:${SCALARDL_VERSION}
volumes:
- ./scalardb.dynamodb.properties:/scalardb.properties
depends_on:
dynamodb:
condition: service_healthy
command:
- "-c"
- "/scalardb.properties"
- "--coordinator"
- "--no-backup"
- "--no-scaling"
networks:
- scalar-network
restart: on-failure
scalar-ledger:
image: ghcr.io/scalar-labs/scalardl-ledger-byol:${SCALARDL_VERSION}
container_name: "scalardl-samples-scalar-ledger-1"
volumes:
- ./fixture/ledger-key.pem:/scalar/ledger-key.pem
- ./fixture/ledger.properties.tmpl:/scalar/ledger/ledger.properties.tmpl
- ./fixture/trial-license-cert.pem:/scalar/license-cert.pem
# If you have a commercial license key, you must use `commercial-license-cert.pem` instead of `trial-license-cert.pem`.
# - ./fixture/commercial-license-cert.pem:/scalar/license-cert.pem
depends_on:
scalardl-ledger-schema-loader:
condition: service_completed_successfully
environment:
- SCALAR_DB_CONTACT_POINTS=sample
- SCALAR_DB_STORAGE=dynamo
- SCALAR_DB_USERNAME=sample
- SCALAR_DB_PASSWORD=sample
- SCALAR_DB_DYNAMO_ENDPOINT_OVERRIDE=http://dynamodb:8000
- SCALAR_DL_LEDGER_PROOF_ENABLED=true
- SCALAR_DL_LEDGER_PROOF_PRIVATE_KEY_PATH=/scalar/ledger-key.pem
##### PLEASE REPLACE THIS VALUE WITH YOUR LICENSE KEY #####
- SCALAR_DL_LICENSING_LICENSE_KEY=<SET_YOUR_LICENSE_KEY>
##### PLEASE REPLACE THIS VALUE WITH YOUR LICENSE KEY #####
networks:
- scalar-network
healthcheck:
test: ["CMD-SHELL", "grpc_health_probe -addr=localhost:50051 && grpc_health_probe -addr=ledger-envoy:50051 || exit 1"]
interval: 1s
timeout: 10s
retries: 60
start_period: 10s