-
Notifications
You must be signed in to change notification settings - Fork 19
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
137 lines (125 loc) · 2.84 KB
/
docker-compose.yml
File metadata and controls
137 lines (125 loc) · 2.84 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
130
131
132
133
134
135
136
137
x-defaults: &defaults
restart: unless-stopped
depends_on:
postgres:
condition: service_healthy
dragonfly:
condition: service_healthy
build: &build
context: .
dockerfile: Dockerfile
environment: &env-vars
DATABASE_URL: ${DATABASE_URL:-postgres://postgres:${POSTGRES_PASSWORD:?}@postgres:5432/namada-indexer}
TENDERMINT_URL: ${TENDERMINT_URL}
CACHE_URL: ${CACHE_URL:-redis://dragonfly:6379}
command: |
./service
extra_hosts:
- "host.docker.internal:host-gateway"
services:
postgres:
image: postgres:16-alpine
command: [ "postgres", "-c", "max_connections=200" ]
expose:
- "5432"
environment:
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:?}
POSTGRES_DB: namada-indexer
healthcheck:
test: [ "CMD-SHELL", "pg_isready -U postgres -d namada-indexer" ]
interval: 5s
timeout: 5s
retries: 5
restart: unless-stopped
volumes:
- type: volume
source: postgres-data
target: /var/lib/postgresql/data
dragonfly:
image: docker.dragonflydb.io/dragonflydb/dragonfly
command: --logtostderr --cache_mode=true --port 6379 -dbnum 1
ulimits:
memlock: -1
expose:
- "6379"
healthcheck:
test: [ "CMD-SHELL", "redis-cli ping | grep PONG" ]
interval: 5s
timeout: 5s
retries: 5
restart: unless-stopped
chain:
<<: *defaults
image: namada/chain-indexer
environment:
<<: *env-vars
INITIAL_QUERY_RETRY_TIME: ${INITIAL_QUERY_RETRY_TIME:-15}
build:
<<: *build
args:
PACKAGE: chain
cometbft:
<<: *defaults
image: namada/cometbft-indexer
environment:
<<: *env-vars
build:
<<: *build
args:
PACKAGE: cometbft
governance:
<<: *defaults
image: namada/governance-indexer
build:
<<: *build
args:
PACKAGE: governance
pos:
<<: *defaults
image: namada/pos-indexer
build:
<<: *build
args:
PACKAGE: pos
rewards:
<<: *defaults
image: namada/rewards-indexer
build:
<<: *build
args:
PACKAGE: rewards
parameters:
<<: *defaults
image: namada/parameters-indexer
build:
<<: *build
args:
PACKAGE: parameters
transactions:
<<: *defaults
image: namada/transaction-indexer
build:
<<: *build
args:
PACKAGE: transactions
webserver:
<<: *defaults
image: namada/webserver-indexer
build:
<<: *build
args:
PACKAGE: webserver
expose:
- 5001
ports:
- ${WEBSERVER_HOST_IP:-127.0.0.1}:${WEBSERVER_PORT:-5001}:5001
environment:
<<: *env-vars
healthcheck:
test: curl --fail http://localhost:5001/health || exit 1
interval: 5s
timeout: 5s
retries: 5
restart: unless-stopped
volumes:
postgres-data: