From 14eca5aea65a2255766a60f1dfd0b00dd0a12250 Mon Sep 17 00:00:00 2001 From: Michael Vines Date: Thu, 24 Oct 2019 13:40:16 -0700 Subject: [PATCH] Remove setup_secondary_mount knowledge from multinode-demo/ (#6530) --- multinode-demo/bootstrap-leader.sh | 2 -- multinode-demo/setup.sh | 1 - multinode-demo/validator.sh | 2 -- net/common.sh | 6 ++++-- 4 files changed, 4 insertions(+), 7 deletions(-) diff --git a/multinode-demo/bootstrap-leader.sh b/multinode-demo/bootstrap-leader.sh index 5982c760ec..2df2ff2e7d 100755 --- a/multinode-demo/bootstrap-leader.sh +++ b/multinode-demo/bootstrap-leader.sh @@ -54,8 +54,6 @@ if [[ -z $CI ]]; then # Skip in CI source "$here"/../scripts/tune-system.sh fi -setup_secondary_mount - # These keypairs are created by ./setup.sh and included in the genesis block identity_keypair=$SOLANA_CONFIG_DIR/bootstrap-leader/identity-keypair.json vote_keypair="$SOLANA_CONFIG_DIR"/bootstrap-leader/vote-keypair.json diff --git a/multinode-demo/setup.sh b/multinode-demo/setup.sh index 2007fa6990..f605cb56ec 100755 --- a/multinode-demo/setup.sh +++ b/multinode-demo/setup.sh @@ -3,7 +3,6 @@ here=$(dirname "$0") # shellcheck source=multinode-demo/common.sh source "$here"/common.sh -setup_secondary_mount set -e diff --git a/multinode-demo/validator.sh b/multinode-demo/validator.sh index 5d589596fe..d1c9f2f675 100755 --- a/multinode-demo/validator.sh +++ b/multinode-demo/validator.sh @@ -185,8 +185,6 @@ if [[ -z "$ledger_dir" ]]; then fi mkdir -p "$ledger_dir" -setup_secondary_mount - if [[ -n $gossip_entrypoint ]]; then # Prefer the --entrypoint argument if supplied... if [[ ${#positional_args[@]} -gt 0 ]]; then diff --git a/net/common.sh b/net/common.sh index 19257513bc..2aca04f8d2 100644 --- a/net/common.sh +++ b/net/common.sh @@ -100,7 +100,7 @@ SOLANA_CONFIG_DIR=$SOLANA_ROOT/config clear_config_dir() { declare config_dir="$1" - setup_secondary_mount + _setup_secondary_mount ( set -x @@ -108,10 +108,12 @@ clear_config_dir() { rm -rf "$config_dir" mkdir -p "$config_dir" ) + + _setup_secondary_mount } SECONDARY_DISK_MOUNT_POINT=/mnt/extra-disk -setup_secondary_mount() { +_setup_secondary_mount() { # If there is a secondary disk, symlink the config/ dir there ( set -x