Skip to content

Commit 7491ba3

Browse files
author
Dmitry Savonin
committed
split blockchain compose file to balancer file
1 parent 82d31a9 commit 7491ba3

File tree

4 files changed

+26
-18
lines changed

4 files changed

+26
-18
lines changed

Makefile

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ install-docker:
55
.PHONY: install-acme
66
install-acme:
77
curl https://get.acme.sh | sh -s email=dmitry@ankr.com
8-
bash ./issue-cert.bash || true
8+
bash ./issue-cert.bash
99

1010
.PHONY: create-genesis
1111
create-genesis:
@@ -20,5 +20,12 @@ run-blockchain:
2020
run-explorer:
2121
docker compose -f ./blockscout/docker-compose.yaml up --build -d
2222

23+
.PHONY: run-balancer
24+
run-balancer:
25+
cat ./balancer/docker-compose.yaml | envsubst | docker-compose -f - up -d
26+
27+
.PHONY: all-no-balancer
28+
all: install-docker create-genesis run-blockchain run-explorer
29+
2330
.PHONY: all
24-
all: install-docker install-acme create-genesis run-blockchain run-explorer
31+
all: install-docker install-acme create-genesis run-blockchain run-explorer run-balancer

balancer/docker-compose.yaml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
version: "3"
2+
services:
3+
nginx:
4+
image: nginx
5+
volumes:
6+
- /root/.acme.sh/:/root/.acme.sh/
7+
- ./nginx.conf:/nginx.conf
8+
environment:
9+
DOMAIN_NAME: "${DOMAIN_NAME}"
10+
ports:
11+
- "443:443"
12+
command: /bin/bash -c "envsubst '${DOMAIN_NAME}' < /nginx.conf > /etc/nginx/conf.d/00-default.conf && cat /etc/nginx/conf.d/00-default.conf && nginx -g 'daemon off;'"
13+
restart: always
File renamed without changes.

docker-compose.yaml

Lines changed: 4 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ services:
1313
volumes:
1414
- "./genesis.json:/datadir/genesis.json"
1515
- "./datadir/bootnode:/datadir/geth"
16+
ports:
17+
- "30303:30303"
1618
restart: always
1719

1820
validator_1:
@@ -165,7 +167,7 @@ services:
165167
- "--faucet.amount=10"
166168
- "--faucet.tiers=5"
167169
ports:
168-
- "8080:8080"
170+
- "3000:8080"
169171
volumes:
170172
- "./genesis.json:/datadir/genesis.json"
171173
- "./keystore:/datadir/keystore"
@@ -176,18 +178,4 @@ services:
176178
image: ankrnetwork/bas-staking-ui:devel
177179
ports:
178180
- "3001:80"
179-
restart: always
180-
nginx:
181-
image: nginx
182-
volumes:
183-
- /root/.acme.sh/:/root/.acme.sh/
184-
- ./nginx.conf:/nginx.conf
185-
environment:
186-
DOMAIN_NAME: "${DOMAIN_NAME}"
187-
ports:
188-
- "443:443"
189-
command: /bin/bash -c "envsubst '${DOMAIN_NAME}' < /nginx.conf > /etc/nginx/conf.d/00-default.conf && cat /etc/nginx/conf.d/00-default.conf && nginx -g 'daemon off;'"
190-
restart: always
191-
192-
volumes:
193-
postgresql_data: { }
181+
restart: always

0 commit comments

Comments
 (0)