Gcloud Create Cluster Flag Recommendations
The following provides more information on the flags used in the create cluster command. You can find more information on Google's website here - [gcloud container clusters create])(https://cloud.google.com/sdk/gcloud/reference/container/clusters/create).
Flag | Description | Recommended value |
---|---|---|
--project | Project the cluster will be deployed to. | --project "$PROJECT_ID" |
--region | The region to deploy the nodes to. | "$HDX_BUCKET_REGION" |
--no-enable-basic-auth | No cluster authorisation is used. | --no-enable-basic-auth |
--release-channel | Clusters subscribed to 'regular' receive versions that are considered GA quality. 'regular' is recommended for production users. | --release-channel "regular" |
--machine-type | The type of machine to use. Hydrolix recommends using n2-standard-16 machines for running a cluster. | --machine-type "n2-standard-16" |
--image-type | Image Type specifies the base OS that the nodes in the cluster will run on. | --image-type "COS_CONTAINERD" |
--disk-type | Type of VM boot disk to be used. | --disk-type "pd-ssd" |
--disk-size | Size of VM boot disk to be used. | --disk-size "192" |
--metadata | Compute Engine metadata to be made available to the guest operating system running on nodes. Addition of the disable-legacy-endpoints set to true. | --metadata disable-legacy-endpoints=true |
--scopes | More information on scopes can be found here | --scopes storage-rw,logging-write,monitoring,service-control,service-management,trace |
--max-pods-per-node | The max number of pods per node for a node pool. | --max-pods-per-node "110" |
--num-nodes | Number of initial nodes to create. | --num-nodes "3" |
--logging | Set the components that have logging enabled. | --logging=SYSTEM,WORKLOAD |
--monitoring | Set the components that have monitoring enabled. | --monitoring=SYSTEM |
--enable-ip-alias | Enable use of alias IPs for Pod IPs | --enable-ip-alias |
--network | The Compute Engine Network that the cluster will connect to. | --network "projects/$PROJECT_ID/global/networks/default" |
--subnetwork | The Google Compute Engine subnetwork to which the cluster is connected. | --subnetwork "projects/$PROJECT_ID/regions/$HDX_BUCKET_REGION/subnetworks/default" |
--no-enable-intra-node-visibility | Turn off intra-node visibility. | --no-enable-intra-node-visibility |
--default-max-pods-per-node | The default max number of pods per node for node pools in the cluster. | --default-max-pods-per-node "110" |
--enable-autoscaling | Enables autoscaling for a node pool. | --enable-autoscaling |
--min-nodes | Minimum number of nodes per zone in the node pool | --min-nodes "0" |
--max-nodes | Maximum number of nodes available for autoscaling. | --max-nodes "20" |
--no-enable-master-authorized-networks | Turn off only allowing only a specified set of CIDR blocks to connect to Kubernetes master. | --no-enable-master-authorized-networks |
--addons | Addons are additional Kubernetes cluster components. Hydrolix uses HorizontalPodAutoscaling, HttpLoadBalancing, GcePersistentDiskCsiDriver | --addons HorizontalPodAutoscaling, HttpLoadBalancing, GcePersistentDiskCsiDriver. |
--enable-autoupgrade | Sets autoupgrade feature for a cluster's default node pool. | --enable-autoupgrade |
--enable-autorepair | Enable node autorepair feature for a cluster's default node pool. | --enable-autorepair |
--max-surge-upgrade | Number of extra (surge) nodes to be created on each upgrade of a node pool. | --max-surge-upgrade 1 |
--max-unavailable-upgrade | Number of nodes that can be unavailable at the same time on each upgrade of a node pool. | --max-unavailable-upgrade 0 |
--enable-shielded-nodes | Enabling Shielded Nodes will enable a more secure Node credential bootstrapping implementation. | --enable-shielded-nodes |
--workload-pool | Enable Workload Identity on the cluster. | --workload-pool="$PROJECT_ID.svc.id.goog" |
--workload-metadata | Type of metadata server available to pods running in the node pool. | --workload-metadata=GKE_METADATA |
Updated about 2 months ago