-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose-auditor.yml
126 lines (119 loc) · 4.43 KB
/
docker-compose-auditor.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
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
services:
scalardl-auditor-schema-loader-cassandra:
image: ghcr.io/scalar-labs/scalardl-schema-loader:${SCALARDL_VERSION}
environment:
- SCHEMA_TYPE=auditor
volumes:
- ./scalardb.properties:/scalardb.properties
depends_on:
cassandra:
condition: service_healthy
command:
- "-c"
- "/scalardb.properties"
- "--coordinator"
- "--replication-factor"
- "1"
networks:
- scalar-network
restart: on-failure
scalar-ledger-as-client:
image: ghcr.io/scalar-labs/scalar-client:${SCALARDL_VERSION}
container_name: "scalardl-samples-scalar-ledger-as-client-1"
volumes:
- ./fixture/ledger.pem:/scalar/ledger.pem
- ./fixture/ledger-key.pem:/scalar/ledger-key.pem
depends_on:
scalar-ledger:
condition: service_healthy
scalar-auditor:
condition: service_healthy
environment:
- SCALAR_DL_CLIENT_SERVER_HOST=ledger-envoy
- SCALAR_DL_CLIENT_AUDITOR_HOST=auditor-envoy
- SCALAR_DL_CLIENT_AUDITOR_ENABLED=true
- SCALAR_DL_CLIENT_CERT_HOLDER_ID=ledger
- SCALAR_DL_CLIENT_CERT_PATH=/scalar/ledger.pem
- SCALAR_DL_CLIENT_PRIVATE_KEY_PATH=/scalar/ledger-key.pem
networks:
- scalar-network
command: |
dockerize -template client.properties.tmpl:client.properties
-template log4j2.properties.tmpl:log4j2.properties
./client/bin/register-cert --config client.properties
restart: on-failure:5
scalar-audior-as-client:
image: ghcr.io/scalar-labs/scalar-client:${SCALARDL_VERSION}
container_name: "scalardl-samples-scalar-auditor-as-client-1"
volumes:
- ./fixture/auditor.pem:/scalar/auditor.pem
- ./fixture/auditor-key.pem:/scalar/auditor-key.pem
depends_on:
scalar-ledger:
condition: service_healthy
scalar-auditor:
condition: service_healthy
environment:
- SCALAR_DL_CLIENT_SERVER_HOST=ledger-envoy
- SCALAR_DL_CLIENT_AUDITOR_HOST=auditor-envoy
- SCALAR_DL_CLIENT_AUDITOR_ENABLED=true
- SCALAR_DL_CLIENT_CERT_HOLDER_ID=auditor
- SCALAR_DL_CLIENT_CERT_PATH=/scalar/auditor.pem
- SCALAR_DL_CLIENT_PRIVATE_KEY_PATH=/scalar/auditor-key.pem
networks:
- scalar-network
command: |
dockerize -template client.properties.tmpl:client.properties
-template log4j2.properties.tmpl:log4j2.properties
./client/bin/register-cert --config client.properties
restart: on-failure:5
scalar-ledger:
environment:
- SCALAR_DL_LEDGER_AUDITOR_ENABLED=true
scalar-auditor:
image: ghcr.io/scalar-labs/scalardl-auditor-byol:${SCALARDL_VERSION}
container_name: "scalardl-samples-scalar-auditor-1"
volumes:
- ./fixture/auditor.pem:/scalar/auditor.pem
- ./fixture/auditor-key.pem:/scalar/auditor-key.pem
- ./fixture/auditor.properties.tmpl:/scalar/auditor/auditor.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-auditor-schema-loader-cassandra:
condition: service_completed_successfully
environment:
- SCALAR_DB_CONTACT_POINTS=cassandra
- SCALAR_DB_STORAGE=cassandra
- SCALAR_DL_AUDITOR_LEDGER_HOST=ledger-envoy
- SCALAR_DL_AUDITOR_CERT_PATH=/scalar/auditor.pem
- SCALAR_DL_AUDITOR_PRIVATE_KEY_PATH=/scalar/auditor-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:40051 && grpc_health_probe -addr=auditor-envoy:40051 || exit 1"]
interval: 1s
timeout: 10s
retries: 60
start_period: 10s
auditor-envoy:
image: ghcr.io/scalar-labs/scalar-envoy:1.5.0
container_name: "scalardl-samples-auditor-envoy-1"
ports:
- "9902:9901"
- "40051:40051"
- "40052:40052"
depends_on:
scalar-auditor:
condition: service_started
environment:
- admin_access_log_path=/dev/stdout
- scalardl_address=scalar-auditor
- service_listeners=scalar-service:40051,scalar-privileged:40052
- envoy_tls=false
networks:
- scalar-network