-
Notifications
You must be signed in to change notification settings - Fork 103
Expand file tree
/
Copy pathdocker-compose.testnet.yml
More file actions
100 lines (91 loc) · 3.03 KB
/
docker-compose.testnet.yml
File metadata and controls
100 lines (91 loc) · 3.03 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
# Testnet is UNSTABLE. Use at your own risk.
services:
snapchain:
image: farcasterxyz/snapchain:latest
pull_policy: always
# build: # For testing
# context: .
# dockerfile: Dockerfile
init: true # Auto-reap zombie processes and forward process signals
environment:
RUST_BACKTRACE: "full"
entrypoint:
- "/bin/bash"
- "-c"
- |
#!/bin/bash
cat > config.toml <<EOF
rpc_address="0.0.0.0:3383"
http_address="0.0.0.0:3381"
rocksdb_dir=".rocks.testnet"
fc_network="Testnet"
read_node = true
[statsd]
prefix="snapchain"
addr="statsd:8125"
use_tags=true
[gossip]
address="/ip4/0.0.0.0/udp/3382/quic-v1"
bootstrap_peers = "/ip4/18.214.165.252/udp/3382/quic-v1, /ip4/3.212.167.138/udp/3382/quic-v1, /ip4/107.21.184.149/udp/3382/quic-v1, /ip4/18.206.50.132/udp/3382/quic-v1,"
[consensus]
validator_addresses=["e89dda4bff3ed5f75f56656a661f9f3e972b7206852dee7bfa65c6cee341e7ae", "719a2a8331e05a3c5e2f4689fc71e7eabfea96d79c69df773a6fc8d8962dfda4", "5b5eb128729aedd86b626f0d60267f770025a551989c422a8f6959ce0bcf24de", "9b8e23233565a6d75e545b3750052ca0a19fe71b21bfb91a020498875f426e2e"]
shard_ids = [1,2]
num_shards = 2
[snapshot]
endpoint_url = "https://e1f9f185c6e63471dd39f96abd3413c4.r2.cloudflarestorage.com"
load_db_from_snapshot=true
EOF
exec $0 $@ # Now run the original command
command: [ "./snapchain", "--config-path", "config.toml" ]
ports:
- "3381:3381/tcp"
- "3382:3382/udp"
- "3383:3383/tcp"
volumes:
- .rocks.testnet:/app/.rocks.testnet
networks:
- snapchain
ulimits:
nofile:
soft: 65535
hard: 65535
# Start this if you want perf metrics for your hubble node. Remember to start `grafana` as well.
statsd:
image: graphiteapp/graphite-statsd:1.1.10-5
restart: unless-stopped
healthcheck:
test: ["CMD", "nc", "-zv", "localhost", "8126"]
interval: 30s
timeout: 5s
retries: 3
start_period: 1m
ports:
# - '80:80' # Graphite web
# - '2003:2003' # Carbon line receiver
# - '2004:2004' # Carbon pickle receiver
# - '7002:7002' # Carbon cache query
- '${STATSD_PUBLISH:-8125}:8125/udp' # StatsD
- '${STATSD_ADMIN_PUBLISH:-8126}:8126' # StatsD admin
networks:
- snapchain
# Start this if you want to see perf metrics for your hubble node. Remember to start `statsd` as well.
grafana:
image: grafana/grafana:10.0.3
restart: unless-stopped
healthcheck:
test: ["CMD", "curl", "-f", "localhost:3000/api/health"]
interval: 30s
timeout: 5s
retries: 3
start_period: 1m
# Mount the grafana config file
volumes:
- ./grafana/grafana.ini:/etc/grafana/grafana.ini
- ./grafana/data:/var/lib/grafana # Persistent Grafana data
ports:
- '3000:3000' # Grafana web
networks:
- snapchain
networks:
snapchain:
driver: bridge