-
Notifications
You must be signed in to change notification settings - Fork 19
Expand file tree
/
Copy pathcompose.yml
More file actions
129 lines (123 loc) · 4.11 KB
/
compose.yml
File metadata and controls
129 lines (123 loc) · 4.11 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
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
127
128
129
# This file is part of https://github.com/midnightntwrk/midnight-node-docker
# Copyright (C) 2025 Midnight Foundation
# SPDX-License-Identifier: Apache-2.0
# Licensed under the Apache License, Version 2.0 (the "License");
# You may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
volumes:
midnight-data-testnet: {}
indexer-data: {}
postgres-data: {}
cardano-ipc: {}
db-sync-data: {}
services:
postgres:
profiles: ["cardano"]
image: postgres:15.3
platform: linux/amd64
container_name: db-sync-postgres
restart: unless-stopped
environment:
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
- POSTGRES_DB=${POSTGRES_DB}
- POSTGRES_USER=${POSTGRES_USER}
volumes:
- postgres-data:/var/lib/postgresql/data
ports:
- "${POSTGRES_PORT}:5432"
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER}"]
interval: 5s
timeout: 5s
retries: 5
cardano-node:
profiles: ["cardano"]
image: ${CARDANO_IMAGE}
platform: linux/amd64
container_name: cardano-node
restart: unless-stopped
environment:
- NETWORK=${CARDANO_NETWORK}
- CARDANO_NODE_SOCKET_PATH=/ipc/node.socket
volumes:
- cardano-ipc:/ipc
- ${CARDANO_DATA_DIR}:/data
ports:
- "3001:3001"
healthcheck:
test: ["CMD-SHELL", "curl -f 127.0.0.1:12788 || exit 1"]
interval: 60s
timeout: 10s
retries: 5
cardano-db-sync:
profiles: ["cardano"]
image: ghcr.io/intersectmbo/cardano-db-sync:13.6.0.4
platform: linux/amd64
container_name: cardano-db-sync
restart: unless-stopped
depends_on:
postgres:
condition: service_healthy
cardano-node:
condition: service_healthy
environment:
- NETWORK=${CARDANO_NETWORK}
- POSTGRES_HOST=${POSTGRES_HOST}
- POSTGRES_PORT=${POSTGRES_PORT}
- POSTGRES_DB=${POSTGRES_DB}
- POSTGRES_USER=${POSTGRES_USER}
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
volumes:
- cardano-ipc:/node-ipc
- db-sync-data:/var/lib/cexplorer
midnight-node-testnet:
container_name: midnight-node
restart: unless-stopped
image: ${MIDNIGHT_NODE_IMAGE}
ports:
- "9944:9944" # WebSocket - For RPC/relay type of nodes (queries, new transaction submissions etc).
- "30333:30333" # P2P Traffic - Peer-to-peer communication for node connectivity.
- "9615:9615" # Prometheus - For monitoring, alerting and observability.
environment:
- APPEND_ARGS=${APPEND_ARGS}
- BOOTNODES=${BOOTNODES}
- CFG_PRESET=${CFG_PRESET}
- DB_SYNC_POSTGRES_CONNECTION_STRING=${DB_SYNC_POSTGRES_CONNECTION_STRING}
- NODE_KEY=${NODE_KEY}
healthcheck:
test: [ "CMD", "curl", "-f", "http://localhost:9944/health" ]
interval: 2s
volumes:
- ./data:/data
- ./envs/${CFG_PRESET}/pc-chain-config.json:/pc-chain-config.json
- midnight-data-testnet:/node
indexer-standalone:
profiles: ["cardano"]
container_name: indexer
restart: unless-stopped
image: ${INDEXER_IMAGE}
ports:
- "8088:8088" # GraphQL API
environment:
# v2.1.4 config structure (testnet-02, qanet)
- APP__CHAIN_INDEXER_APPLICATION__NETWORK_ID=${INDEXER_NETWORK_ID}
- APP__WALLET_INDEXER_APPLICATION__NETWORK_ID=${INDEXER_NETWORK_ID}
- APP__INFRA__API__NETWORK_ID=${INDEXER_NETWORK_ID}
# v3.x config structure (preview)
- APP__APPLICATION__NETWORK_ID=${INDEXER_NETWORK_ID}
- APP__INFRA__NODE__URL=ws://midnight-node:9944
- APP__INFRA__STORAGE__CNN_URL=/data/indexer.sqlite
- APP__INFRA__SECRET=${INDEXER_SECRET}
depends_on:
midnight-node-testnet:
condition: service_healthy
volumes:
- indexer-data:/data