Create a node pool

Creates a new node pool for the designated Kubernetes cluster.

Permissions and scopes

To call this operation, you need permissions, based on the model you're using:

  • Identity and access permissions. Your user needs a role with these permissions. Learn more.

    • Roles: lkecluster_admin
  • OAuth scopes. Your user needs these scopes assigned. Learn more.

    • Scopes: lke:read_write

CLI

linode-cli lke pool-create 12345 \
  --type g6-standard-4 \
  --count 6 \
  --tags example-tag \
  --autoscaler.enabled true \
  --autoscaler.max 12 \
  --autoscaler.min 3 \
  --labels '{ "example.com/my-app":"team1" }' \
  --taints.effect "NoSchedule" \
  --taints.key "example.com/my-app" \
  --taints.value "teamA"

Learn more

Path Params
string
enum
required

Enum Call either the v4 URL, or v4beta for operations still in Beta.

Allowed:
integer
required

ID of the Kubernetes cluster to look up.

Body Params

Configuration for the node pool.

autoscaler
object

When enabled, the number of nodes automatically scales within the defined minimum and maximum values. When making a request, max and min require each other.

integer
required
1 to 100

The number of nodes in the node pool.

string
enum
Defaults to disabled

Local disk encryption setting for this LKE node pool. Defaults to disabled.

Allowed:
disks
array of objects

This node pool's custom disk layout. Each item in this array will create a new disk partition for each node in this node pool.

📘

Omit this field, except for special use cases. The disks specified here are partitions in addition to the primary partition and reduce the size of the primary partition. This can lead to stability problems for the node.

  • The custom disk layout is applied to each node in this node pool.

  • The maximum number of custom disk partitions that can be configured is 7.

  • Once the requested disk partitions are allocated, the remaining disk space is allocated to the node's boot disk.

  • A node pool's custom disk layout is immutable over the lifetime of the node pool.

disks
integer

Beta, LKE Enterprise The id of the Cloud Firewall that you wish to assign to this node pool. Review Recommended firewall settings to learn which rules should be configured within your firewall for compatibility with LKE.

🚧

This field is available as part of the beta API and can only be used by accounts with access to LKE Enterprise. Call the URL with the apiVersion path parameter set to v4beta.

string

Beta, LKE Enterprise The LKE-specific Kubernetes version to use for the worker nodes within this node pool. This field is required when creating node pools on LKE Enterprise clusters.

🚧

This field is available as part of the beta API and can only be used by accounts with access to LKE Enterprise. Call the URL with the apiVersion path parameter set to v4beta.

string
length between 1 and 32

An optional label for this node pool. Labels can be up to 32 characters long, containing lowercase alphanumeric characters optionally interspersed with dashes.

A node pool's label also cascades down to its nodes (Linodes). If a label is defined on the node pool, the label for each node is <cluster-id>-<nodepool-label>-<hash>. If not, the label is <cluster-id>-<nodepool-id>-<hash>.

labels
object

Key-value pairs added as labels to nodes in the node pool. Labels help classify your nodes and easily select subsets of objects. To learn more, review the Labels and taints guide.

Label key:

  • A key can contain alphanumeric characters, dashes (-), underscores (_), or dots (.). Start and end it with an alphanumeric character.

  • If the key begins with a DNS subdomain prefix followed by a single slash, for example example.com/my-app, the maximum total length of the label key is 128 characters. Domain labels can be up to 62 characters after the '/'. The prefix needs to adhere to RFC 1123 DNS subdomain restrictions.

  • If the key doesn't begin with a DNS subdomain prefix, the maximum key length is 63 characters.

Specifying an empty object removes all previously set labels.

Label value:

  • The label's value can contain alphanumeric characters, dashes (-), underscores (_), or dots (.). Start and end it with an alphanumeric character.

  • Can be specified as an empty string value with "".

tags
array of strings

Filterable Organizational tags to apply to this node pool. When you apply tags to LKE Enterprise node pools, they also apply to the nodes (Linodes) within the node pool. Tags don't cascade down to nodes in non-Enterprise node pools.

tags
taints
array of objects
length ≥ 0

Kubernetes taints to add to node pool nodes. Taints help control how pods are scheduled onto nodes, specifically allowing them to repel certain pods. To learn more, review the Labels and taints guide.

Specifying an empty array ([]) removes all previously set taints.

taints
string
required

The Linode type for all of the nodes in the node pool.

string
enum

Beta, LKE Enterprise Determines when the worker nodes within this node pool upgrade to the latest selected Kubernetes version, after the cluster has been upgraded. This field is required when creating node pools on LKE Enterprise clusters.

  • rolling_update: Immediately triggers a recycle of this node pool when the Kubernetes version is updated.
  • on_recycle (default): Does not trigger any immediate recycle. New worker nodes are created with the new Kubernetes version. Existing worker nodes will be upgraded when a recycle is manually triggered.
🚧

This field is available as part of the beta API and can only be used by accounts with access to LKE Enterprise. Call the URL with the apiVersion path parameter set to v4beta.

Allowed:
Responses

Language
Credentials
Response
Choose an example:
application/json