From b83fcd5e5caab6d39af86a84c51001d713994aa8 Mon Sep 17 00:00:00 2001 From: Adam Szkoda Date: Tue, 11 Aug 2020 02:16:33 +0000 Subject: [PATCH] Local testnet fixes (#1499) Fixes some outdated instructions and improves scripts portability so that they work e.g. on NixOS. --- scripts/local_testnet/README.md | 20 ++++++++++---------- scripts/local_testnet/beacon_node.sh | 2 +- scripts/local_testnet/second_beacon_node.sh | 2 +- scripts/local_testnet/setup.sh | 2 +- scripts/local_testnet/validator_client.sh | 2 +- 5 files changed, 14 insertions(+), 14 deletions(-) diff --git a/scripts/local_testnet/README.md b/scripts/local_testnet/README.md index 0a8de1759..c9934ef98 100644 --- a/scripts/local_testnet/README.md +++ b/scripts/local_testnet/README.md @@ -19,26 +19,26 @@ Assuming you are happy with the configuration in `var.env`, create the testnet directory, genesis state and validator keys with: ```bash -./setup +./setup.sh ``` Start the first beacon node: ```bash -./beacon_node +./beacon_node.sh ``` In a new terminal, start the validator client which will attach to the first beacon node: ```bash -./validator_client +./validator_client.sh ``` In a new terminal, start the second beacon node which will peer with the first: ```bash -./second_beacon_node +./second_beacon_node.sh ``` ## Additional Info @@ -49,9 +49,9 @@ The beacon nodes and validator client have their `--debug-level` set to `info`. Specify a different debug level like this: ```bash -./validator_client debug -./beacon_node trace -./second_beacon_node warn +./validator_client.sh debug +./beacon_node.sh trace +./second_beacon_node.sh warn ``` ### Starting fresh @@ -59,7 +59,7 @@ Specify a different debug level like this: Delete the current testnet and all related files using: ```bash -./clean +./clean.sh ``` @@ -71,9 +71,9 @@ genesis state will be far in the future, causing lots of skip slots. Update the genesis time to now using: ```bash -./reset_genesis_time +./reset_genesis_time.sh ``` > Note: you probably want to drop the beacon node database and the validator > client slashing database if you do this. When using small validator counts -> it's probably easy to just use `./clean && ./setup`. +> it's probably easy to just use `./clean.sh && ./setup.sh`. diff --git a/scripts/local_testnet/beacon_node.sh b/scripts/local_testnet/beacon_node.sh index f3fab6d4c..56c632802 100755 --- a/scripts/local_testnet/beacon_node.sh +++ b/scripts/local_testnet/beacon_node.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Starts a beacon node based upon a genesis state created by diff --git a/scripts/local_testnet/second_beacon_node.sh b/scripts/local_testnet/second_beacon_node.sh index 4bef7ec63..ddba99b46 100755 --- a/scripts/local_testnet/second_beacon_node.sh +++ b/scripts/local_testnet/second_beacon_node.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Starts a beacon node based upon a genesis state created by diff --git a/scripts/local_testnet/setup.sh b/scripts/local_testnet/setup.sh index a43bad7ea..8b7118354 100755 --- a/scripts/local_testnet/setup.sh +++ b/scripts/local_testnet/setup.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Produces a testnet specification and a genesis state where the genesis time diff --git a/scripts/local_testnet/validator_client.sh b/scripts/local_testnet/validator_client.sh index 9d6397754..aab44045a 100755 --- a/scripts/local_testnet/validator_client.sh +++ b/scripts/local_testnet/validator_client.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Starts a validator client based upon a genesis state created by