Commit fed1d947 authored by Warren Strange's avatar Warren Strange

added shell guard in case var is not set

parent 24b06d80
...@@ -47,7 +47,7 @@ function create-master-instance() { ...@@ -47,7 +47,7 @@ function create-master-instance() {
[[ -n ${1:-} ]] && address_opt="--address ${1}" [[ -n ${1:-} ]] && address_opt="--address ${1}"
local preemptible_master="" local preemptible_master=""
if [[ "${PREEMPTIBLE_MASTER}" == "true" ]]; then if [[ "${PREEMPTIBLE_MASTER:-}" == "true" ]]; then
preemptible_master="--preemptible --maintenance-policy TERMINATE" preemptible_master="--preemptible --maintenance-policy TERMINATE"
fi fi
......
...@@ -34,7 +34,7 @@ function create-master-instance { ...@@ -34,7 +34,7 @@ function create-master-instance {
local address_opt="" local address_opt=""
[[ -n ${1:-} ]] && address_opt="--address ${1}" [[ -n ${1:-} ]] && address_opt="--address ${1}"
local preemptible_master="" local preemptible_master=""
if [[ "${PREEMPTIBLE_MASTER}" == "true" ]]; then if [[ "${PREEMPTIBLE_MASTER:-}" == "true" ]]; then
preemptible_master="--preemptible --maintenance-policy TERMINATE" preemptible_master="--preemptible --maintenance-policy TERMINATE"
fi fi
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment