github.com/nathanielks/terraform@v0.6.1-0.20170509030759-13e1a62319dc/website/source/docs/providers/google/r/container_node_pool.html.markdown (about)

     1  ---
     2  layout: "google"
     3  page_title: "Google: google_container_node_pool"
     4  sidebar_current: "docs-google-container-node-pool"
     5  description: |-
     6    Manages a GKE NodePool resource.
     7  ---
     8  
     9  # google\_container\_node\_pool
    10  
    11  Manages a Node Pool resource within GKE. For more information see
    12  [the official documentation](https://cloud.google.com/container-engine/docs/node-pools)
    13  and
    14  [API](https://cloud.google.com/container-engine/reference/rest/v1/projects.zones.clusters.nodePools).
    15  
    16  ## Example usage
    17  
    18  ```hcl
    19  resource "google_container_node_pool" "np" {
    20    name               = "my-node-pool"
    21    zone               = "us-central1-a"
    22    cluster            = "${google_container_cluster.primary.name}"
    23    initial_node_count = 3
    24  }
    25  
    26  resource "google_container_cluster" "primary" {
    27    name               = "marcellus-wallace"
    28    zone               = "us-central1-a"
    29    initial_node_count = 3
    30  
    31    additional_zones = [
    32      "us-central1-b",
    33      "us-central1-c",
    34    ]
    35  
    36    master_auth {
    37      username = "mr.yoda"
    38      password = "adoy.rm"
    39    }
    40  
    41    node_config {
    42      oauth_scopes = [
    43        "https://www.googleapis.com/auth/compute",
    44        "https://www.googleapis.com/auth/devstorage.read_only",
    45        "https://www.googleapis.com/auth/logging.write",
    46        "https://www.googleapis.com/auth/monitoring",
    47      ]
    48    }
    49  }
    50  ```
    51  
    52  ## Argument Reference
    53  
    54  * `zone` - (Required) The zone in which the cluster resides.
    55  
    56  * `cluster` - (Required) The cluster to create the node pool for.
    57  
    58  * `initial_node_count` - (Required) The initial node count for the pool.
    59  
    60  - - -
    61  
    62  * `project` - (Optional) The project in which to create the node pool. If blank,
    63      the provider-configured project will be used.
    64  
    65  * `name` - (Optional) The name of the node pool. If left blank, Terraform will
    66      auto-generate a unique name.
    67  
    68  * `name_prefix` - (Optional) Creates a unique name for the node pool beginning
    69      with the specified prefix. Conflicts with `name`.