forked from openwallet-foundation/didcomm-mediator-service
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.multi-agent.yml
121 lines (114 loc) · 4.01 KB
/
docker-compose.multi-agent.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
version: '3'
networks:
mediator-network:
name: mediator-network
driver: bridge
elk-network:
name: ${ELK_NETWORK_NAME}
driver: bridge
volumes:
agency-wallet:
mediator-controller-data:
# x-env: &defaults
# MEDIATOR_CONTROLLER_PORT: ${MEDIATOR_CONTROLLER_PORT:-3010}
services:
caddy:
image: caddy
hostname: caddy
networks:
- mediator-network
ports: # Uncomment to access caddy outside of containers
- 2015:2015
# - 2019:2019
volumes:
- ./caddy/Caddyfile:/etc/caddy/Caddyfile:z
healthcheck:
# Port 2019 is an internal Caddy admin port.
test: nc -zv localhost:2019 || exit -1
interval: 3s
timeout: 3s
start_period: 10s
retries: 5
ngrok:
image: ngrok/ngrok
restart: unless-stopped
hostname: ngrok
depends_on:
caddy:
condition: service_healthy
networks:
- mediator-network
environment:
- NGROK_AUTHTOKEN=${NGROK_AUTHTOKEN}
command: http caddy:2015 --log stdout
# ports: # Uncomment to access ngrok outside of containers
# - 4040:4040 # admin port
healthcheck:
test: /bin/bash -c "</dev/tcp/ngrok/4040"
interval: 3s
timeout: 3s
start_period: 5s
retries: 5
mediator:
build:
context: .
dockerfile: acapy/Dockerfile.acapy
depends_on:
db:
condition: service_healthy
ngrok:
condition: service_healthy
restart: unless-stopped
environment:
- ENV=${ENV:-local}
- POSTGRESQL_HOST=${POSTGRESQL_HOST:-db}
- POSTGRESQL_PORT=${POSTGRESQL_PORT:-5432}
- ACAPY_WALLET_STORAGE_CONFIG={"url":"${POSTGRESQL_HOST:-db}:${POSTGRESQL_PORT:-5432}","wallet_scheme":"DatabasePerWallet"}
- ACAPY_WALLET_STORAGE_CREDS={"account":"${POSTGRESQL_USER:-postgres}","password":"${POSTGRESQL_PASSWORD:-development}","admin_account":"${POSTGRESQL_ADMIN_USER:-postgres}","admin_password":"${POSTGRESQL_ADMIN_PASSWORD:-development}"}
- ACAPY_WALLET_NAME=${MEDIATOR_WALLET_NAME:-mediator}
- ACAPY_WALLET_KEY=${MEDIATOR_WALLET_KEY:-testing}
- MEDIATOR_AGENT_HTTP_IN_PORT=${MEDIATOR_AGENT_HTTP_IN_PORT:-3000}
- MEDIATOR_AGENT_WS_IN_PORT=${MEDIATOR_AGENT_WS_IN_PORT:-3001}
- MEDIATOR_AGENT_HTTP_ADMIN_PORT=${MEDIATOR_AGENT_HTTP_ADMIN_PORT:-3002}
- MEDIATOR_AGENT_ADMIN_MODE=${MEDIATOR_AGENT_ADMIN_MODE:-admin-api-key 7gdmVBiJalMj52Oum50yD8neu/nxmv3/DTWcZPyKZ4K2UdNNwSPKgg==}
- MEDIATOR_AGENT_LABEL=${MEDIATOR_AGENT_LABEL:-Mediator}
- MEDIATOR_URL=${MEDIATOR_URL:-MEDIATOR_URL}
- MEDIATOR_ENDPOINT_URL=${MEDIATOR_ENDPOINT_URL:-localhost}
- MEDIATOR_ARG_FILE=${MEDIATOR_ARG_FILE:-./configs/mediator-auto-accept.yml}
- MEDIATOR_CONTROLLER_WEBHOOK=${MEDIATOR_CONTROLLER_WEBHOOK:-http://mediator-controller:3010/webhooks}
- MEDIATOR_AGENT_ADMIN_API_KEY=${MEDIATOR_AGENT_ADMIN_API_KEY}
- LOG_LEVEL=${LOG_LEVEL}
- ACAPY_LOG_LEVEL=${LOG_LEVEL}
- RUST_LOG=${RUST_LOG:-ERROR}
- ACAPY_TRACE=${ACAPY_TRACE}
- ACAPY_TRACE_TARGET=${ACAPY_TRACE_TARGET}
- ACAPY_TRACE_TAG=${ACAPY_TRACE_TAG}
- ACAPY_TRACE_LABEL=${ACAPY_TRACE_LABEL}
# ports: # Uncomment to access mediator outside of containers
# - ${MEDIATOR_AGENT_HTTP_ADMIN_PORT:-3002}:${MEDIATOR_AGENT_HTTP_ADMIN_PORT:-3002}
# - ${MEDIATOR_AGENT_HTTP_IN_PORT:-3000}:${MEDIATOR_AGENT_HTTP_IN_PORT:-3000}
# - ${MEDIATOR_AGENT_WS_IN_PORT:-3001}:${MEDIATOR_AGENT_WS_IN_PORT:-3001}
networks:
- mediator-network
- elk-network
healthcheck:
test: /bin/bash -c "</dev/tcp/mediator/3000"
interval: 5s
timeout: 5s
retries: 5
db:
image: postgres:15
# restart: always
environment:
POSTGRES_PASSWORD: ${POSTGRESQL_ADMIN_PASSWORD:-development}
# ports: # Uncomment to access postgres outside of containers
# - "5432:5432"
networks:
- mediator-network
volumes:
- agency-wallet:/var/lib/pgsql/data:z
healthcheck:
test: pg_isready -U postgres
interval: 3s
timeout: 3s
retries: 5