mirror of
https://github.com/status-im/nimbus-eth2.git
synced 2025-01-10 22:36:01 +00:00
reset_testnet.sh: push the Docker image right after building it [skip ci]
and let Watchtower manage container restart
This commit is contained in:
parent
9aeef775ae
commit
c39ca5b5c3
@ -68,7 +68,6 @@ if [ "$ETH1_PRIVATE_KEY" != "" ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
cd docker
|
cd docker
|
||||||
make build
|
|
||||||
|
|
||||||
$DOCKER_BEACON_NODE makeDeposits \
|
$DOCKER_BEACON_NODE makeDeposits \
|
||||||
--quickstart-deposits=$QUICKSTART_VALIDATORS \
|
--quickstart-deposits=$QUICKSTART_VALIDATORS \
|
||||||
@ -111,15 +110,13 @@ if [[ $PUBLISH_TESTNET_RESETS != "0" ]]; then
|
|||||||
> /tmp/reset-network.sh
|
> /tmp/reset-network.sh
|
||||||
|
|
||||||
bash /tmp/reset-network.sh
|
bash /tmp/reset-network.sh
|
||||||
|
rm /tmp/reset-network.sh
|
||||||
|
|
||||||
echo Uploading bootstrap node network key
|
echo Uploading bootstrap node network key
|
||||||
BOOTSTRAP_NODE_DOCKER_PATH=/docker/beacon-node-$NETWORK-1/data/BeaconNode/
|
BOOTSTRAP_NODE_DOCKER_PATH=/docker/beacon-node-$NETWORK-1/data/BeaconNode/
|
||||||
scp "$DATA_DIR_ABS/privkey.protobuf" $BOOTSTRAP_HOST:/tmp/
|
scp "$DATA_DIR_ABS/privkey.protobuf" $BOOTSTRAP_HOST:/tmp/
|
||||||
ssh $BOOTSTRAP_HOST "sudo install -o dockremap -g docker /tmp/privkey.protobuf $BOOTSTRAP_NODE_DOCKER_PATH"
|
ssh $BOOTSTRAP_HOST "sudo install -o dockremap -g docker /tmp/privkey.protobuf $BOOTSTRAP_NODE_DOCKER_PATH"
|
||||||
|
|
||||||
echo Publishing docker image...
|
|
||||||
make push-last
|
|
||||||
|
|
||||||
echo Persisting testnet data to git...
|
echo Persisting testnet data to git...
|
||||||
pushd "$NETWORK_DIR_ABS"
|
pushd "$NETWORK_DIR_ABS"
|
||||||
git add $COMMITTED_FILES
|
git add $COMMITTED_FILES
|
||||||
@ -127,9 +124,19 @@ if [[ $PUBLISH_TESTNET_RESETS != "0" ]]; then
|
|||||||
git push
|
git push
|
||||||
popd
|
popd
|
||||||
|
|
||||||
../env.sh nim --verbosity:0 manage_testnet_hosts.nims restart_nodes \
|
#../env.sh nim --verbosity:0 manage_testnet_hosts.nims restart_nodes \
|
||||||
--network=$NETWORK \
|
#--network=$NETWORK \
|
||||||
> /tmp/restart-nodes.sh
|
#> /tmp/restart-nodes.sh
|
||||||
|
|
||||||
bash /tmp/restart-nodes.sh
|
#bash /tmp/restart-nodes.sh
|
||||||
|
#rm /tmp/restart-nodes.sh
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
echo "Building Docker image..."
|
||||||
|
make build
|
||||||
|
|
||||||
|
echo "Publishing Docker image..."
|
||||||
|
make push-last
|
||||||
|
|
||||||
|
echo "A Watchtower systemd service will pull the new image and start new containers based on it, on each testnet host, in the next 2 minutes."
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user