Commit 4b99aafc authored by Dawn Chen's avatar Dawn Chen

Fix kube-push using gcloud compute instance-groups managed set-instance-template`

parent 11fcd3bb
...@@ -1032,10 +1032,11 @@ function prepare-push() { ...@@ -1032,10 +1032,11 @@ function prepare-push() {
# being used, create a temp one, then delete the old one and recreate it once again. # being used, create a temp one, then delete the old one and recreate it once again.
create-node-instance-template "tmp" create-node-instance-template "tmp"
gcloud compute instance-groups managed --zone "${ZONE}" \ gcloud compute instance-groups managed \
set-template "${NODE_INSTANCE_PREFIX}-group" \ set-instance-template "${NODE_INSTANCE_PREFIX}-group" \
--project "${PROJECT}" \ --template "${NODE_INSTANCE_PREFIX}-template-tmp" \
--template "${NODE_INSTANCE_PREFIX}-template-tmp" || true; --zone "${ZONE}" \
--project "${PROJECT}" || true;
gcloud compute instance-templates delete \ gcloud compute instance-templates delete \
--project "${PROJECT}" \ --project "${PROJECT}" \
...@@ -1044,10 +1045,11 @@ function prepare-push() { ...@@ -1044,10 +1045,11 @@ function prepare-push() {
create-node-instance-template create-node-instance-template
gcloud compute instance-groups managed --zone "${ZONE}" \ gcloud compute instance-groups managed \
set-template "${NODE_INSTANCE_PREFIX}-group" \ set-instance-template "${NODE_INSTANCE_PREFIX}-group" \
--project "${PROJECT}" \ --template "${NODE_INSTANCE_PREFIX}-template" \
--template "${NODE_INSTANCE_PREFIX}-template" || true; --zone "${ZONE}" \
--project "${PROJECT}" || true;
gcloud compute instance-templates delete \ gcloud compute instance-templates delete \
--project "${PROJECT}" \ --project "${PROJECT}" \
......
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