mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-14 06:15:45 +00:00
GKE provider: Add cluster-ipv4-cidr and arbitrary flags
This commit is contained in:
parent
a167a6b4df
commit
e42f201189
@ -124,9 +124,11 @@ function validate-cluster {
|
|||||||
# ZONE
|
# ZONE
|
||||||
# CLUSTER_API_VERSION (optional)
|
# CLUSTER_API_VERSION (optional)
|
||||||
# NUM_NODES
|
# NUM_NODES
|
||||||
# ADDITIONAL_ZONES
|
# ADDITIONAL_ZONES (optional)
|
||||||
# NODE_SCOPES
|
# NODE_SCOPES
|
||||||
# MACHINE_TYPE
|
# MACHINE_TYPE
|
||||||
|
# CLUSTER_IP_RANGE (optional)
|
||||||
|
# GKE_CREATE_FLAGS (optional, space delineated)
|
||||||
function kube-up() {
|
function kube-up() {
|
||||||
echo "... in gke:kube-up()" >&2
|
echo "... in gke:kube-up()" >&2
|
||||||
detect-project >&2
|
detect-project >&2
|
||||||
@ -166,6 +168,12 @@ function kube-up() {
|
|||||||
create_args+=("--additional-zones=${ADDITIONAL_ZONES}")
|
create_args+=("--additional-zones=${ADDITIONAL_ZONES}")
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [[ ! -z "${CLUSTER_IP_RANGE:-}" ]]; then
|
||||||
|
create_args+=("--cluster-ipv4-cidr=${CLUSTER_IP_RANGE}")
|
||||||
|
fi
|
||||||
|
|
||||||
|
create_args+=( ${GKE_CREATE_FLAGS:-} )
|
||||||
|
|
||||||
# Bring up the cluster.
|
# Bring up the cluster.
|
||||||
"${GCLOUD}" ${CMD_GROUP:-} container clusters create "${CLUSTER_NAME}" "${create_args[@]}"
|
"${GCLOUD}" ${CMD_GROUP:-} container clusters create "${CLUSTER_NAME}" "${create_args[@]}"
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user