-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathdocker-compose.yml
executable file
·120 lines (112 loc) · 3.81 KB
/
docker-compose.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
version: '3.8'
services:
prepare-full-node:
image: debian:bullseye-slim
restart: "no"
command: ["bash", "/home/pocket/.poktroll/scripts/init-poktrolld.sh"]
environment:
- NETWORK_NAME=${NETWORK_NAME}
volumes:
- ./poktrolld-data:/home/pocket/.poktroll/
- ./scripts/:/home/pocket/.poktroll/scripts
# Necessary to change ownership of the files, as our production image does not run the process under root.
- ./relayminer:/home/pocket/.poktroll/relayminer
- ./gateway:/home/pocket/.poktroll/gateway
# Full node
full-node:
container_name: full-node
image: ${POKTROLLD_IMAGE_REPO}:${POKTROLLD_IMAGE_TAG_BASE:-0.0.10}
entrypoint: ["sh", "/home/pocket/start-poktrolld.sh"]
environment:
- NODE_HOSTNAME=${NODE_HOSTNAME}
- POKTROLLD_LOG_LEVEL=${POKTROLLD_LOG_LEVEL}
- DAEMON_NAME=poktrolld
- DAEMON_HOME=/home/pocket/.poktroll
- DAEMON_RESTART_AFTER_UPGRADE=true
- DAEMON_ALLOW_DOWNLOAD_BINARIES=true
- UNSAFE_SKIP_BACKUP=false
ports:
- "26657:26657"
- "26656:26656"
- "9090:9090"
restart: unless-stopped
depends_on:
prepare-full-node:
condition: service_completed_successfully
volumes:
- /etc/ssl/:/etc/ssl/
- ./poktrolld-data:/home/pocket/.poktroll/
- ./scripts/start-poktrolld.sh:/home/pocket/start-poktrolld.sh
- ./stake_configs:/poktroll/stake_configs
# Relay Miner
relayminer:
image: ${POKTROLLD_IMAGE_REPO}:${POKTROLLD_IMAGE_TAG_OFF_CHAIN:-latest}
container_name: relayminer
entrypoint: ["sh", "/home/pocket/start-relayminer.sh"]
environment:
- SUPPLIER_MNEMONIC=${SUPPLIER_MNEMONIC}
ports:
- "8545:8545" # 8545 is the port RelayMiner is configured to listen on in `relayminer_config.yaml`.
restart: unless-stopped
depends_on:
- full-node
volumes:
- /etc/ssl/:/etc/ssl/
- ./relayminer:/home/pocket/.poktroll/
- ./scripts/start-relayminer.sh:/home/pocket/start-relayminer.sh
# PATH Gateway
# TODO_TECHDEBT(@okdas): Rename the container to be consistent with both LocalNet and
# when grafana dashboards once PATH metrics are available.
gateway:
image: ${PATH_GATEWAY_IMAGE_REPO}:${PATH_GATEWAY_IMAGE_TAG:-development}
container_name: gateway
ports:
- "3069:3069"
restart: unless-stopped
depends_on:
- full-node
volumes:
- ./gateway/config/gateway_config.yaml:/app/config/.config.yaml
command:
- ./path
# Prometheus
prometheus:
image: prom/prometheus:latest
container_name: prometheus
restart: unless-stopped
volumes:
- prometheus_data:/prometheus
- ./prometheus/prometheus.yml:/etc/prometheus/prometheus.yml
command:
- "--config.file=/etc/prometheus/prometheus.yml"
- "--storage.tsdb.path=/prometheus"
# Uncomment if you need direct access to prometheus. It is advised to keep it unexposed to the internet.
# ports:
# - "9191:9090"
# Grafana
grafana:
image: grafana/grafana-oss:latest
container_name: grafana
environment:
- GF_SERVER_HTTP_PORT=3000
depends_on:
- prometheus
ports:
- "3000:3000"
restart: unless-stopped
volumes:
- grafana_data:/var/lib/grafana
- ./grafana/dashboards:/var/lib/grafana/dashboards
- ./grafana/dashboard.yml:/etc/grafana/provisioning/dashboards/main.yaml
- ./grafana/datasource.yml:/etc/grafana/provisioning/datasources/datasource.yml
- ./grafana/grafana.ini:/etc/grafana/grafana.ini
debian:
image: debian:latest
container_name: debian-shell
command: "tail -f /dev/null" # Keeps the container running
stdin_open: true # Allows interaction
tty: true # Enables terminal support
# Define named volumes
volumes:
prometheus_data:
grafana_data: