Add option to pass boot disk type to gce create (#1308)

This commit is contained in:
sakridge
2018-09-22 16:43:47 -07:00
committed by GitHub
parent a51c2f193e
commit 3199f174a3
2 changed files with 15 additions and 4 deletions

View File

@ -113,6 +113,7 @@ cloud_CreateInstances() {
declare optionalBootDiskSize="$6"
declare optionalStartupScript="$7"
declare optionalAddress="$8"
declare optionalBootDiskType="$9"
declare nodes
if [[ $numNodes = 1 ]]; then
@ -143,6 +144,11 @@ cloud_CreateInstances() {
--metadata-from-file "startup-script=$optionalStartupScript"
)
fi
if [[ -n $optionalBootDiskType ]]; then
args+=(
--boot-disk-type "${optionalBootDiskType}"
)
fi
if [[ -n $optionalAddress ]]; then
[[ $numNodes = 1 ]] || {