From 676e3e19265ce3f483301f73a4cd8982e02f21c2 Mon Sep 17 00:00:00 2001 From: Yihau Chen Date: Tue, 28 Feb 2023 13:14:44 +0800 Subject: [PATCH] fix: remove unnecessary --allow-private-addr setup (#30552) --- net/common.sh | 1 - net/net.sh | 9 +++------ system-test/testnet-automation.sh | 7 +------ 3 files changed, 4 insertions(+), 13 deletions(-) diff --git a/net/common.sh b/net/common.sh index 8e46adb72e737b..fbe534576af000 100644 --- a/net/common.sh +++ b/net/common.sh @@ -69,7 +69,6 @@ loadConfigFile() { entrypointIp=${validatorIpList[0]} else entrypointIp=${validatorIpListPrivate[0]} - maybeAllowPrivateAddr='--allow-private-addr' fi buildSshOptions diff --git a/net/net.sh b/net/net.sh index ee1881eae4b22b..8ac6343c3c951a 100755 --- a/net/net.sh +++ b/net/net.sh @@ -323,7 +323,7 @@ startBootstrapLeader() { $nodeIndex \ ${#clientIpList[@]} \"$benchTpsExtraArgs\" \ \"$genesisOptions\" \ - \"$maybeNoSnapshot $maybeSkipLedgerVerify $maybeLimitLedgerSize $maybeWaitForSupermajority $maybeAllowPrivateAddr $maybeAccountsDbSkipShrink $maybeSkipRequireTower\" \ + \"$maybeNoSnapshot $maybeSkipLedgerVerify $maybeLimitLedgerSize $maybeWaitForSupermajority $maybeAccountsDbSkipShrink $maybeSkipRequireTower\" \ \"$gpuMode\" \ \"$maybeWarpSlot\" \ \"$maybeFullRpc\" \ @@ -397,7 +397,7 @@ startNode() { $nodeIndex \ ${#clientIpList[@]} \"$benchTpsExtraArgs\" \ \"$genesisOptions\" \ - \"$maybeNoSnapshot $maybeSkipLedgerVerify $maybeLimitLedgerSize $maybeWaitForSupermajority $maybeAllowPrivateAddr $maybeAccountsDbSkipShrink $maybeSkipRequireTower\" \ + \"$maybeNoSnapshot $maybeSkipLedgerVerify $maybeLimitLedgerSize $maybeWaitForSupermajority $maybeAccountsDbSkipShrink $maybeSkipRequireTower\" \ \"$gpuMode\" \ \"$maybeWarpSlot\" \ \"$maybeFullRpc\" \ @@ -797,7 +797,6 @@ maybeLimitLedgerSize="" maybeSkipLedgerVerify="" maybeDisableAirdrops="" maybeWaitForSupermajority="" -maybeAllowPrivateAddr="" maybeAccountsDbSkipShrink="" maybeSkipRequireTower="" debugBuild=false @@ -942,9 +941,7 @@ while [[ -n $1 ]]; do extraPrimordialStakes=$2 shift 2 elif [[ $1 = --allow-private-addr ]]; then - # May also be added by loadConfigFile if 'gce.sh create' was invoked - # without -P. - maybeAllowPrivateAddr="$1" + echo "--allow-private-addr is a default value" shift 1 elif [[ $1 = --accounts-db-skip-shrink ]]; then maybeAccountsDbSkipShrink="$1" diff --git a/system-test/testnet-automation.sh b/system-test/testnet-automation.sh index ec0844679daf23..a326fb06db4853 100755 --- a/system-test/testnet-automation.sh +++ b/system-test/testnet-automation.sh @@ -136,11 +136,6 @@ function launch_testnet() { maybeAsyncNodeInit="--async-node-init" fi - declare maybeAllowPrivateAddr - if [[ "$ALLOW_PRIVATE_ADDR" = "true" ]]; then - maybeAllowPrivateAddr="--allow-private-addr" - fi - declare maybeExtraPrimordialStakes if [[ -n "$EXTRA_PRIMORDIAL_STAKES" ]]; then maybeExtraPrimordialStakes="--extra-primordial-stakes $EXTRA_PRIMORDIAL_STAKES" @@ -151,7 +146,7 @@ function launch_testnet() { "${REPO_ROOT}"/net/net.sh start $version_args \ -c idle=$NUMBER_OF_CLIENT_NODES $maybeStartAllowBootFailures \ --gpu-mode $startGpuMode $maybeWarpSlot $maybeAsyncNodeInit \ - $maybeExtraPrimordialStakes $maybeAllowPrivateAddr + $maybeExtraPrimordialStakes if [[ -n "$WAIT_FOR_EQUAL_STAKE" ]]; then wait_for_equal_stake