generated from subsquid-labs/squid-ink-template
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdocker-compose.archive.yml
71 lines (65 loc) · 1.99 KB
/
docker-compose.archive.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
version: "3"
services:
archive-db:
image: postgres:12 # CockroachDB cluster might be a better fit for production deployment
container_name: archive-db
restart: always
volumes:
- /var/lib/postgresql/data
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: squid-archive
archive-ingest:
image: subsquid/substrate-ingest:firesquid
container_name: archive-ingest
depends_on:
- archive-db
restart: on-failure
command: [
"-e", "ws://smartnode:9943", # smartnet node endpoint
"-c", "10", # allow up to 10 pending requests for the above endpoint (default is 5)
"--prom-port", "9090", # prometheus port
"--write-batch-size", "500", # The number of blocks to write in a single SQL transaction
"--out", "postgres://postgres:postgres@archive-db:5432/squid-archive"
]
environment:
NODE_TLS_REJECT_UNAUTHORIZED: 0 # allow ws connections
ports:
- "9090:9090"
# localhost:8000
archive-gateway:
image: subsquid/substrate-gateway:firesquid
container_name: archive-gateway
depends_on:
- archive-db
environment:
RUST_LOG: "substrate_gateway=info,actix_server=info"
command: [
"--database-url", "postgres://postgres:postgres@archive-db:5432/squid-archive",
"--database-max-connections", "5", # max number of concurrent database connections
"--contracts-support"
]
ports:
- "${GATEWAY_HOST}:${GATEWAY_PORT}:8000"
# localhost:9000
# Explorer service.
# It provides rich GraphQL API for querying archived data
archive-explorer:
image: subsquid/substrate-explorer:firesquid
container_name: archive-explorer
depends_on:
- archive-db
environment:
DB_TYPE: postgres
DB_HOST: archive-db
DB_PORT: "5432"
DB_NAME: "squid-archive"
DB_USER: "postgres"
DB_PASS: "postgres"
ports:
- "4444:9000"
networks:
default:
external:
name: node-network