sample gke cluster for play and fun.
As an option, there is a possibility to add in ArgoCD /w app-of-apps pattern. Please see separate deployment instructions under argo
folder.
Simple GKE cluster with output of kubeconfig
Name | Description | Type | Default | Required |
---|---|---|---|---|
cluster_name_suffix | A suffix to append to the default cluster name | string |
"" |
no |
compute_engine_service_account | Service account to associate to the nodes in the cluster | any |
n/a | yes |
ip_range_pods | The secondary ip range to use for pods | any |
n/a | yes |
ip_range_services | The secondary ip range to use for services | any |
n/a | yes |
network | The VPC network to host the cluster in | any |
n/a | yes |
project_id | The project ID to host the cluster in | any |
n/a | yes |
region | The region to host the cluster in | any |
n/a | yes |
skip_provisioners | Flag to skip local-exec provisioners | bool |
false |
no |
subnetwork | The subnetwork to host the cluster in | any |
n/a | yes |
Name | Description |
---|---|
ca_certificate | n/a |
client_token | n/a |
cluster_name | Cluster name |
ip_range_pods | The secondary IP range used for pods |
ip_range_services | The secondary IP range used for services |
kubeconfig_raw | n/a |
kubernetes_endpoint | n/a |
location | n/a |
master_kubernetes_version | The master Kubernetes version |
network | n/a |
project_id | n/a |
region | n/a |
service_account | The default service account used for running nodes. |
subnetwork | n/a |
zones | List of zones in which the cluster resides |
To provision this example, run the following from within this directory:
gcloud auth application-default login --project [gcp-project-name]
to set the google context Reference material hereterraform init
to get the pluginsterraform plan
to see the infrastructure planterraform apply
to apply the infrastructure buildterraform destroy
to destroy the built infrastructure
To use the cluster from kubectl do following:
gcloud container clusters get-credentials CLUSTER_NAME
add in new context in your $home/.kube/config Reference material here