diff --git a/start_node_genesis_gcp.sh b/start_node_genesis_gcp.sh index 8f03b1dec..cd8dd26ae 100644 --- a/start_node_genesis_gcp.sh +++ b/start_node_genesis_gcp.sh @@ -48,7 +48,12 @@ function parse_options() { } # Parse options. -SEASON="$1" +if [[ "$1" = 'dev' ]] || [[ "$1" = 'staging' ]] || [[ "$1" = 'sandbox' ]] || [[ "$1" = 'exp' ]] || [[ "$1" = 'spring' ]] || [[ "$1" = 'summer' ]] || [[ "$1" = 'mainnet' ]]; then + SEASON="$1" +else + printf "Invalid project/season argument: $1\n" + exit +fi GCP_USER="$2" number_re='^[0-9]+$' diff --git a/start_node_genesis_onprem.sh b/start_node_genesis_onprem.sh index c99692d68..8249e5503 100644 --- a/start_node_genesis_onprem.sh +++ b/start_node_genesis_onprem.sh @@ -58,7 +58,12 @@ function parse_options() { } # Parse options. -SEASON="$1" +if [[ "$1" = 'staging' ]] || [[ "$1" = 'spring' ]] || [[ "$1" = 'mainnet' ]]; then + SEASON="$1" +else + printf "Invalid project/season argument: $1\n" + exit +fi ONPREM_USER="$2" number_re='^[0-9]+$' diff --git a/start_node_incremental_gcp.sh b/start_node_incremental_gcp.sh index 9cb9767c8..e70433c57 100644 --- a/start_node_incremental_gcp.sh +++ b/start_node_incremental_gcp.sh @@ -47,7 +47,12 @@ function parse_options() { } # Parse options. -SEASON="$1" +if [[ "$1" = 'dev' ]] || [[ "$1" = 'staging' ]] || [[ "$1" = 'sandbox' ]] || [[ "$1" = 'exp' ]] || [[ "$1" = 'spring' ]] || [[ "$1" = 'summer' ]] || [[ "$1" = 'mainnet' ]]; then + SEASON="$1" +else + printf "Invalid project/season argument: $1\n" + exit +fi GCP_USER="$2" number_re='^[0-9]+$' diff --git a/start_node_incremental_onprem.sh b/start_node_incremental_onprem.sh index 4d3a6c1b7..e76aacbc6 100644 --- a/start_node_incremental_onprem.sh +++ b/start_node_incremental_onprem.sh @@ -57,7 +57,12 @@ function parse_options() { } # Parse options. -SEASON="$1" +if [[ "$1" = 'staging' ]] || [[ "$1" = 'spring' ]] || [[ "$1" = 'mainnet' ]]; then + SEASON="$1" +else + printf "Invalid project/season argument: $1\n" + exit +fi ONPREM_USER="$2" number_re='^[0-9]+$'