2019-03-20 00:05:10 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
set -eu
|
|
|
|
cd $(dirname "$0")
|
|
|
|
|
|
|
|
NETWORK_NAME=$1
|
|
|
|
source "$NETWORK_NAME.env"
|
|
|
|
|
|
|
|
cd ..
|
|
|
|
|
2019-03-27 13:04:09 +00:00
|
|
|
NIM_FLAGS="-d:release --lineTrace:on -d:chronicles_log_level=DEBUG -d:SECONDS_PER_SLOT=$SECONDS_PER_SLOT -d:SHARD_COUNT=$SHARD_COUNT -d:SLOTS_PER_EPOCH=$SLOTS_PER_EPOCH"
|
|
|
|
|
|
|
|
BEACON_NODE_BIN=${NETWORK_NAME}_node
|
|
|
|
|
2019-03-27 16:16:03 +00:00
|
|
|
nim c $NIM_FLAGS -o:"./$BEACON_NODE_BIN" beacon_chain/beacon_node
|
2019-03-22 14:35:20 +00:00
|
|
|
|
|
|
|
if [ ! -d ~/.cache/nimbus/BeaconNode/$NETWORK_NAME/validators ]; then
|
2019-03-27 16:12:48 +00:00
|
|
|
./$BEACON_NODE_BIN --network=$NETWORK_NAME importValidator
|
2019-03-22 14:35:20 +00:00
|
|
|
fi
|
|
|
|
|
2019-03-28 17:30:32 +00:00
|
|
|
./$BEACON_NODE_BIN --network=$NETWORK_NAME --tcpPort:$BOOTSTRAP_PORT --udpPort:$BOOTSTRAP_PORT
|
2019-03-20 00:05:10 +00:00
|
|
|
|