ContainerNodePool

Property Value
Google Cloud Service Name Kubernetes Engine
Google Cloud Service Documentation /kubernetes-engine/docs/
Google Cloud REST Resource Name v1.projects.locations.clusters.nodePools
Google Cloud REST Resource Documentation /kubernetes-engine/docs/reference/rest/v1/projects.locations.clusters.nodePools
Config Connector Resource Short Names gcpcontainernodepool
gcpcontainernodepools
containernodepool
Config Connector Service Name container.googleapis.com
Config Connector Resource Fully Qualified Name containernodepools.container.cnrm.cloud.google.com
Can Be Referenced by IAMPolicy/IAMPolicyMember No

Custom Resource Definition Properties

Annotations

Fields
cnrm.cloud.google.com/project-id

Spec

Schema

  autoscaling:
    maxNodeCount: integer
    minNodeCount: integer
  clusterRef:
    external: string
    name: string
    namespace: string
  initialNodeCount: integer
  location: string
  management:
    autoRepair: boolean
    autoUpgrade: boolean
  maxPodsPerNode: integer
  namePrefix: string
  nodeConfig:
    bootDiskKMSCryptoKeyRef:
      external: string
      name: string
      namespace: string
    diskSizeGb: integer
    diskType: string
    guestAccelerator:
    - count: integer
      type: string
    imageType: string
    kubeletConfig:
      cpuCfsQuota: boolean
      cpuCfsQuotaPeriod: string
      cpuManagerPolicy: string
    labels:
      string: string
    linuxNodeConfig:
      sysctls:
        string: string
    localSsdCount: integer
    machineType: string
    metadata:
      string: string
    minCpuPlatform: string
    oauthScopes:
    - string
    preemptible: boolean
    sandboxConfig:
      sandboxType: string
    serviceAccountRef:
      external: string
      name: string
      namespace: string
    shieldedInstanceConfig:
      enableIntegrityMonitoring: boolean
      enableSecureBoot: boolean
    tags:
    - string
    taint:
    - effect: string
      key: string
      value: string
    workloadMetadataConfig:
      nodeMetadata: string
  nodeCount: integer
  nodeLocations:
  - string
  resourceID: string
  upgradeSettings:
    maxSurge: integer
    maxUnavailable: integer
  version: string
Fields

autoscaling

Optional

object

Configuration required by cluster autoscaler to adjust the size of the node pool to the current cluster usage.

autoscaling.maxNodeCount

Required*

integer

Maximum number of nodes in the NodePool. Must be >= min_node_count.

autoscaling.minNodeCount

Required*

integer

Minimum number of nodes in the NodePool. Must be >=0 and <= max_node_count.

clusterRef

Required

object

clusterRef.external

Optional

string

The name of a ContainerCluster.

clusterRef.name

Optional

string

Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

clusterRef.namespace

Optional

string

Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/

initialNodeCount

Optional

integer

Immutable. The initial number of nodes for the pool. In regional or multi-zonal clusters, this is the number of nodes per zone. Changing this will force recreation of the resource.

location

Required

string

Immutable. The location (region or zone) of the cluster.

management

Optional

object

Node management configuration, wherein auto-repair and auto-upgrade is configured.

management.autoRepair

Optional

boolean

Whether the nodes will be automatically repaired.

management.autoUpgrade

Optional

boolean

Whether the nodes will be automatically upgraded.

maxPodsPerNode

Optional

integer

Immutable. The maximum number of pods per node in this node pool. Note that this does not work on node pools which are "route-based" - that is, node pools belonging to clusters that do not have IP Aliasing enabled.

namePrefix

Optional

string

Immutable. Creates a unique name for the node pool beginning with the specified prefix. Conflicts with name.

nodeConfig

Optional

object

Immutable.

nodeConfig.bootDiskKMSCryptoKeyRef

Optional

object

nodeConfig.bootDiskKMSCryptoKeyRef.external

Optional

string

The selfLink of a KMSCryptoKey.

nodeConfig.bootDiskKMSCryptoKeyRef.name

Optional

string

Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

nodeConfig.bootDiskKMSCryptoKeyRef.namespace

Optional

string

Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/

nodeConfig.diskSizeGb

Optional

integer

Immutable.

nodeConfig.diskType

Optional

string

Immutable.

nodeConfig.guestAccelerator

Optional

list (object)

Immutable.

nodeConfig.guestAccelerator.[]

Optional

object

nodeConfig.guestAccelerator.[].count

Required*

integer

Immutable.

nodeConfig.guestAccelerator.[].type

Required*

string

Immutable.

nodeConfig.imageType

Optional

string

nodeConfig.kubeletConfig

Optional

object

nodeConfig.kubeletConfig.cpuCfsQuota

Optional

boolean

nodeConfig.kubeletConfig.cpuCfsQuotaPeriod

Optional

string

nodeConfig.kubeletConfig.cpuManagerPolicy

Required*

string

nodeConfig.labels

Optional

map (key: string, value: string)

Immutable.

nodeConfig.linuxNodeConfig

Optional

object

nodeConfig.linuxNodeConfig.sysctls

Required*

map (key: string, value: string)

nodeConfig.localSsdCount

Optional

integer

Immutable.

nodeConfig.machineType

Optional

string

Immutable.

nodeConfig.metadata

Optional

map (key: string, value: string)

Immutable.

nodeConfig.minCpuPlatform

Optional

string

Immutable.

nodeConfig.oauthScopes

Optional

list (string)

Immutable.

nodeConfig.oauthScopes.[]

Optional

string

nodeConfig.preemptible

Optional

boolean

Immutable.

nodeConfig.sandboxConfig

Optional

object

Immutable.

nodeConfig.sandboxConfig.sandboxType

Required*

string

nodeConfig.serviceAccountRef

Optional

object

nodeConfig.serviceAccountRef.external

Optional

string

The email of an IAMServiceAccount.

nodeConfig.serviceAccountRef.name

Optional

string

Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

nodeConfig.serviceAccountRef.namespace

Optional

string

Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/

nodeConfig.shieldedInstanceConfig

Optional

object

Immutable.

nodeConfig.shieldedInstanceConfig.enableIntegrityMonitoring

Optional

boolean

Immutable.

nodeConfig.shieldedInstanceConfig.enableSecureBoot

Optional

boolean

Immutable.

nodeConfig.tags

Optional

list (string)

Immutable.

nodeConfig.tags.[]

Optional

string

nodeConfig.taint

Optional

list (object)

Immutable.

nodeConfig.taint.[]

Optional

object

nodeConfig.taint.[].effect

Required*

string

Immutable.

nodeConfig.taint.[].key

Required*

string

Immutable.

nodeConfig.taint.[].value

Required*

string

Immutable.

nodeConfig.workloadMetadataConfig

Optional

object

nodeConfig.workloadMetadataConfig.nodeMetadata

Required*

string

nodeCount

Optional

integer

The number of nodes per instance group. This field can be used to update the number of nodes per instance group but should not be used alongside autoscaling.

nodeLocations

Optional

list (string)

The list of zones in which the node pool's nodes should be located. Nodes must be in the region of their regional cluster or in the same region as their cluster's zone for zonal clusters. If unspecified, the cluster-level node_locations will be used.

nodeLocations.[]

Optional

string

resourceID

Optional

string

Immutable. Optional. The name of the resource. Used for creation and acquisition. When unset, the value of `metadata.name` is used as the default.

upgradeSettings

Optional

object

Specify node upgrade settings to change how many nodes GKE attempts to upgrade at once. The number of nodes upgraded simultaneously is the sum of max_surge and max_unavailable. The maximum number of nodes upgraded simultaneously is limited to 20.

upgradeSettings.maxSurge

Required*

integer

The number of additional nodes that can be added to the node pool during an upgrade. Increasing max_surge raises the number of nodes that can be upgraded simultaneously. Can be set to 0 or greater.

upgradeSettings.maxUnavailable

Required*

integer

The number of nodes that can be simultaneously unavailable during an upgrade. Increasing max_unavailable raises the number of nodes that can be upgraded in parallel. Can be set to 0 or greater.

version

Optional

string

* Field is required when parent field is specified

Status

Schema

  conditions:
  - lastTransitionTime: string
    message: string
    reason: string
    status: string
    type: string
  instanceGroupUrls:
  - string
Fields
conditions

list (object)

Conditions represents the latest available observation of the resource's current state.

conditions.[]

object

conditions.[].lastTransitionTime

string

Last time the condition transitioned from one status to another.

conditions.[].message

string

Human-readable message indicating details about last transition.

conditions.[].reason

string

Unique, one-word, CamelCase reason for the condition's last transition.

conditions.[].status

string

Status is the status of the condition. Can be True, False, Unknown.

conditions.[].type

string

Type is the type of the condition.

instanceGroupUrls

list (string)

The resource URLs of the managed instance groups associated with this node pool.

instanceGroupUrls.[]

string

Sample YAML(s)

Typical Use Case

  # Copyright 2020 Google LLC
  #
  # Licensed under the Apache License, Version 2.0 (the "License");
  # you may not use this file except in compliance with the License.
  # You may obtain a copy of the License at
  #
  #     http://www.apache.org/licenses/LICENSE-2.0
  #
  # Unless required by applicable law or agreed to in writing, software
  # distributed under the License is distributed on an "AS IS" BASIS,
  # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  # See the License for the specific language governing permissions and
  # limitations under the License.
  
  apiVersion: container.cnrm.cloud.google.com/v1beta1
  kind: ContainerNodePool
  metadata:
    labels:
      label-one: "value-one"
    name: containernodepool-sample
  spec:
    location: us-east1-c
    autoscaling:
      minNodeCount: 1
      maxNodeCount: 3
    nodeConfig:
      machineType: n1-standard-1
      diskSizeGb: 100
      diskType: pd-standard
      tags:
        - tagone
        - tagtwo
      preemptible: false
      minCpuPlatform: "Intel Haswell"
      oauthScopes:
        - "https://www.googleapis.com/auth/logging.write"
        - "https://www.googleapis.com/auth/monitoring"
      guestAccelerator:
        - type: "nvidia-tesla-k80"
          count: 1
      metadata:
        disable-legacy-endpoints: "true"
    management:
      autoRepair: true
      autoUpgrade: true
    clusterRef:
      name: containernodepool-dep
  ---
  apiVersion: container.cnrm.cloud.google.com/v1beta1
  kind: ContainerCluster
  metadata:
    annotations:
      cnrm.cloud.google.com/remove-default-node-pool: "true"
    name: containernodepool-dep
  spec:
    location: us-east1-c
    initialNodeCount: 1