github.com/turtlemonvh/terraform@v0.6.9-0.20151204001754-8e40b6b855e8/website/source/docs/providers/google/r/container_cluster.html.markdown (about) 1 --- 2 layout: "google" 3 page_title: "Google: google_container_cluster" 4 sidebar_current: "docs-google-container-cluster" 5 description: |- 6 Creates a GKE cluster. 7 --- 8 9 # google\_container\_cluster 10 11 -> **Note:** Due to limitations of the API, all arguments except `node_version` are non-updateable (changing any will cause recreation of the whole cluster). 12 13 ## Example usage 14 15 ``` 16 resource "google_container_cluster" "primary" { 17 name = "marcellus-wallace" 18 zone = "us-central1-a" 19 initial_node_count = 3 20 21 master_auth { 22 username = "mr.yoda" 23 password = "adoy.rm" 24 } 25 } 26 ``` 27 28 ## Argument Reference 29 30 * `name` - (Required) The name of the cluster, unique within the project and zone 31 * `zone` - (Required) The zone that all resources should be created in. 32 * `master_auth` - (Required) The authentication information for accessing the Kubernetes master 33 * `initial_node_count` - (Required) The number of nodes to create in this cluster (not including the Kubernetes master) 34 * `description` - (Optional) Description of the cluster 35 * `node_version` - (Optional) The Kubernetes version on the nodes. Only valid for upgrading of existing cluster. 36 Defaults to latest version supported by the server. 37 * `cluster_ipv4_cidr` - (Optional) The IP address range of the container pods in this cluster. 38 Default is an automatically assigned CIDR. 39 * `logging_service` - (Optional) The logging service that the cluster should write logs to. 40 Available options include `logging.googleapis.com` and `none`. Defaults to `logging.googleapis.com` 41 * `monitoring_service` - (Optional) The monitoring service that the cluster should write metrics to. 42 Available options include `monitoring.googleapis.com` and `none`. Defaults to `monitoring.googleapis.com` 43 * `network` - (Optional) The name of the Google Compute Engine network to which the cluster is connected 44 * `node_config` - (Optional)The machine type and image to use for all nodes in this cluster 45 46 **Master Auth** supports the following arguments: 47 48 * `password` - The password to use for HTTP basic authentication when accessing the Kubernetes master endpoint 49 * `username` - The username to use for HTTP basic authentication when accessing the Kubernetes master endpoint 50 51 **Node Config** supports the following arguments: 52 53 * `machine_type` - (Optional) The name of a Google Compute Engine machine type. 54 Defaults to `n1-standard-1`. 55 * `disk_size_gb` - (Optional) Size of the disk attached to each node, specified in GB. 56 The smallest allowed disk size is 10GB. Defaults to 100GB. 57 * `oauth_scopes` - (Optional) The set of Google API scopes to be made available on all 58 of the node VMs under the "default" service account. The following scopes are necessary 59 to ensure the correct functioning of the cluster: 60 61 * `https://www.googleapis.com/auth/compute` 62 * `https://www.googleapis.com/auth/devstorage.read_only` 63 * `https://www.googleapis.com/auth/logging.write` (if `logging_service` points to Google) 64 * `https://www.googleapis.com/auth/monitoring` (if `monitoring_service` points to Google) 65 66 ## Attributes Reference 67 68 * `master_auth.client_certificate` - Base64 encoded public certificate 69 used by clients to authenticate to the cluster endpoint. 70 * `master_auth.client_key` - Base64 encoded private key used by clients 71 to authenticate to the cluster endpoint 72 * `master_auth.cluster_ca_certificate` - Base64 encoded public certificate 73 that is the root of trust for the cluster 74 * `endpoint` - The IP address of this cluster's Kubernetes master 75 * `instance_group_urls` - List of instance group URLs which have been assigned to the cluster