This repository has been archived by the owner on Nov 29, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathdocker-compose.yaml
167 lines (164 loc) · 6.04 KB
/
docker-compose.yaml
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
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
version: "2.4"
services:
caddy:
image: abiosoft/caddy:no-stats
container_name: caddy
restart: always
environment:
ACME_AGREE: "true"
ports:
- 9934:9934
- 9945:9945
- 80:80
- 443:443
volumes:
- ./Caddyfile:/etc/Caddyfile
- ./caddy:/root/.caddy
generate_sr_key:
container_name: generate_sr_key
build:
context: ./
dockerfile: Dockerfile.subkey
command: bash -c "subkey generate --scheme sr25519"
generate_ed_key:
container_name: generate_ed_key
build:
context: ./
dockerfile: Dockerfile.subkey
command: bash -c "subkey inspect --scheme ed25519 ''"
create_chain_spec:
container_name: create_chain_spec
image: cerebellumnetwork/pos-node:v2.3.1
user: root
volumes:
- ./spec-data:/cereio/spec-data
command: bash -c "mkdir -p ~/spec && /usr/local/bin/cere build-spec --disable-default-bootnode --chain local > /cereio/spec-data/customSpec.json"
create_raw_chain_spec:
container_name: create_raw_chain_spec
image: cerebellumnetwork/pos-node:v2.3.1
user: root
volumes:
- ./spec-data:/cereio/spec-data
command: bash -c "/usr/local/bin/cere build-spec --chain=/cereio/spec-data/customSpec.json --raw --disable-default-bootnode > /cereio/spec-data/customSpecRaw.json"
boot_node:
container_name: boot_node
image: cerebellumnetwork/pos-node:${VERSION}
restart: always
logging:
driver: "json-file"
options:
max-size: "20m"
ports:
- "127.0.0.1:9944:9944"
- "127.0.0.1:9933:9933"
- "30333:30333"
volumes:
- ./spec-data:/cereio/spec-data
- ./chain-data:/data
command: bash -c "/usr/local/bin/cere -l${LOG_LEVEL} --name ${NODE_NAME} --chain /cereio/spec-data/${SPEC_PATH}/customSpecRaw.json --telemetry-url 'wss://telemetry.polkadot.io/submit/ 0' --validator --ws-port 9944 --rpc-methods=Unsafe --ws-external --unsafe-ws-external --rpc-cors all --rpc-external ${CUSTOM_PARAMETERS}"
add_validation_node_custom:
container_name: add_validation_node_custom
image: cerebellumnetwork/pos-node:${VERSION}
restart: always
logging:
driver: "json-file"
options:
max-size: "20m"
ports:
- "127.0.0.1:9944:9944"
- "127.0.0.1:9933:9933"
- "30333:30333"
volumes:
- ./spec-data:/cereio/spec-data
- ./chain-data:/data
command: bash -c "/usr/local/bin/cere -l${LOG_LEVEL} --name ${NODE_NAME} --chain /cereio/spec-data/${SPEC_PATH}/customSpecRaw.json --telemetry-url 'wss://telemetry.polkadot.io/submit/ 0' --validator --bootnodes /ip4/${BOOT_NODE_IP_ADDRESS}/tcp/30333/p2p/${NETWORK_IDENTIFIER} /ip4/${BOOT_NODE_IP_ADDRESS_2}/tcp/30333/p2p/${NETWORK_IDENTIFIER_2} --ws-port 9944 --rpc-methods=Unsafe --ws-external --unsafe-ws-external --rpc-cors all --rpc-external ${CUSTOM_PARAMETERS}"
add_validator:
container_name: add_validator
image: add_validator_script
environment:
- "GENERATE_ACCOUNTS=${GENERATE_ACCOUNTS}"
- "NETWORK=${NETWORK}"
logging:
driver: "json-file"
options:
max-size: "20m"
build:
context: ./scripts
dockerfile: add-validator/Dockerfile.addValidator
command: npm run add-validator
generate_accounts:
container_name: generate_accounts
image: generate_accounts
user: root
logging:
driver: "json-file"
options:
max-size: "20m"
build:
context: ./scripts/generate-accounts
dockerfile: Dockerfile.generateAccounts
volumes:
- ./scripts/generate-accounts/accounts:/app/accounts
- ./scripts/generate-accounts/keys:/app/keys
command: npm run generate-accounts
generate_emulations_chain_spec:
container_name: generate_emulations_chain_spec
image: generate_emulations_chain_spec
user: root
logging:
driver: "json-file"
options:
max-size: "20m"
build:
context: ./
dockerfile: scripts/emulations/Dockerfile.generateEmulationsChainSpec
volumes:
- ./scripts/generate-accounts/accounts:/app/accounts
- ./spec-data:/app/spec-data
command: npm run generate-chain-spec
execute_emulations:
container_name: execute_emulations
image: execute_emulations
user: root
logging:
driver: "json-file"
options:
max-size: "20m"
build:
context: ./scripts
dockerfile: emulations/Dockerfile.emulations
volumes:
- ./scripts/generate-accounts/accounts:/app/accounts
command: npm run emulations
full_node:
container_name: cere_full_node
image: cerebellumnetwork/pos-node:${VERSION}
restart: always
logging:
driver: "json-file"
options:
max-size: "20m"
ports:
- "9944:9944"
- "9933:9933"
- "30333:30333"
volumes:
- ./spec-data:/cereio/spec-data
- ./chain-data:/data
command: bash -c "/usr/local/bin/cere -l${LOG_LEVEL} --name ${NODE_NAME} --chain /cereio/spec-data/${SPEC_PATH}/customSpecRaw.json --telemetry-url 'wss://telemetry.polkadot.io/submit/ 0' --bootnodes /ip4/${BOOT_NODE_IP_ADDRESS}/tcp/30333/p2p/${NETWORK_IDENTIFIER} /ip4/${BOOT_NODE_IP_ADDRESS_2}/tcp/30333/p2p/${NETWORK_IDENTIFIER_2} --ws-port 9944 --ws-external --rpc-methods=Auto --rpc-cors all --rpc-external ${CUSTOM_PARAMETERS}"
archive_node:
container_name: cere_archive_node
image: cerebellumnetwork/pos-node:${VERSION}
restart: always
logging:
driver: "json-file"
options:
max-size: "20m"
ports:
- "9944:9944"
- "9933:9933"
- "30333:30333"
volumes:
- ./spec-data:/cereio/spec-data
- ./chain-data:/data
command: bash -c "/usr/local/bin/cere -l${LOG_LEVEL} --name ${NODE_NAME} --chain /cereio/spec-data/${SPEC_PATH}/customSpecRaw.json --pruning archive --telemetry-url 'wss://telemetry.polkadot.io/submit/ 0' --bootnodes /ip4/${BOOT_NODE_IP_ADDRESS}/tcp/30333/p2p/${NETWORK_IDENTIFIER} /ip4/${BOOT_NODE_IP_ADDRESS_2}/tcp/30333/p2p/${NETWORK_IDENTIFIER_2} --ws-port 9944 --rpc-methods=Unsafe --ws-external --unsafe-ws-external --rpc-cors all --rpc-external ${CUSTOM_PARAMETERS}"