Merge branch 'interopenv'

This commit is contained in:
Ștefan Talpalaru 2019-09-05 12:42:01 +02:00
commit 2527ab8b10
No known key found for this signature in database
GPG Key ID: CBF7934204F1B6F9
3 changed files with 12 additions and 7 deletions

View File

@ -21,8 +21,10 @@ make update deps # build dependencies
Look in the scripts for options - the default config is a small setup using the `minimal` state spec.
```
cd interop
# Clear data from previous run, then start a new simulation
rm -rf data ; ./start.sh
rm -rf data; ./start.sh
# In a separate terminal, can run another beacon node, such as lighthouse:
./run_lighthouse.sh

View File

@ -21,9 +21,9 @@ LAST_VALIDATOR_IDX=$(( (NUM_VALIDATORS / ($NUM_NODES + $NUM_MISSING_NODES)) * ($
mkdir -p $DATA_DIR/validators
rm -f $DATA_DIR/validators/*
pushd $VALIDATORS_DIR
pushd $VALIDATORS_DIR >/dev/null
cp $(seq -s " " -f v%07g.privkey $FIRST_VALIDATOR_IDX $LAST_VALIDATOR_IDX) $DATA_DIR/validators
popd
popd >/dev/null
$BEACON_NODE_BIN \
--network:$NETWORK_METADATA_FILE \

View File

@ -1,9 +1,12 @@
#!/bin/bash
set -euo pipefail
set -eo pipefail
# Read in variables
. "$(dirname "$0")/vars.sh"
source "$(dirname "$0")/vars.sh"
# set up the environment
source "${SIM_ROOT}/../env.sh"
cd "$SIM_ROOT"
mkdir -p "$SIMULATION_DIR"
@ -13,7 +16,7 @@ cd "$GIT_ROOT"
make update deps
NIMFLAGS="-d:chronicles_log_level=DEBUG --hints:off --opt:speed --debuginfo"
NIMFLAGS="-d:chronicles_log_level=DEBUG --hints:off --warnings:off --opt:speed --debuginfo"
# For interop, we run the minimal config
DEFS="-d:const_preset=minimal"
@ -23,7 +26,7 @@ LAST_VALIDATOR="$VALIDATORS_DIR/v$(printf '%07d' $LAST_VALIDATOR_NUM).deposit.js
[[ -x "$BEACON_NODE_BIN" ]] || {
echo "Building $BEACON_NODE_BIN ($DEFS)"
"$SIM_ROOT/../env.sh" nim c -o:"$BEACON_NODE_BIN" $NIMFLAGS $DEFS beacon_chain/beacon_node
nim c -o:"$BEACON_NODE_BIN" $NIMFLAGS $DEFS beacon_chain/beacon_node
}
if [ ! -f "${LAST_VALIDATOR}" ]; then