Use auto mode networks instead of legacy networks in GCP

Use of the --range flag creates legacy networks in GCP.
This commit is contained in:
Bowei Du
2017-04-11 14:35:18 -07:00
parent c68ae58c93
commit 079505023f
3 changed files with 2 additions and 3 deletions

View File

@@ -650,7 +650,7 @@ function create-network() {
echo "Creating new network: ${NETWORK}"
# The network needs to be created synchronously or we have a race. The
# firewalls can be added concurrent with instance creation.
gcloud compute networks create --project "${PROJECT}" "${NETWORK}" --range "10.240.0.0/16"
gcloud compute networks create --project "${PROJECT}" "${NETWORK}" --mode=auto
fi
if ! gcloud compute firewall-rules --project "${PROJECT}" describe "${CLUSTER_NAME}-default-internal-master" &>/dev/null; then