Documentation Index

Fetch the complete documentation index at: https://api.ncloud-docs.com/llms.txt

Use this file to discover all available pages before exploring further.

Create NodePool

Prev Next

Available in VPC

Create a NodePool that sets the number of WorkerNodes in the cluster, their specifications, and more.

Request

This section describes the request format. The method and URI are as follows:

Method URI
POST /vnks/v2/clusters/{uuid}/node-pool (Korea Region)
POST /vnks/sgn-v2/clusters/{uuid}/node-pool (Singapore Region)
POST /vnks/jpn-v2/clusters/{uuid}/node-pool (Japan Region)

Request headers

For information about the headers common to all Ncloud Kubernetes Service APIs, see Common Ncloud Kubernetes Service headers.

Request path parameters

You can use the following path parameters with your request:

Field Type Required Description
uuid String Required Cluster UUID

Request body

You can include the following data in the body of your request:

Field Type Required Description
name String Required NodePool name
nodeCount Integer Conditional Number of nodes to be registered
  • Required when autoscaling is not enabled
softwareCode String Optional Server image code
serverSpecCode String Optional Server specification code
storageSize Integer Optional Storage size
autoscale Array Optional Autoscale option
autoscale.enabled Boolean Optional Auto scaling availability
  • true | false
    • true: Enable auto scaling.
    • false: Disable auto scaling.
autoscale.max Integer Optional Maximum number of nodes available for auto scaling
  • Up to 250
autoscale.min Integer Optional Minimum number of nodes available for auto scaling
  • 1 or more
labels[] Array Optional Labels to apply to all nodes in the NodePool
labels[].key String Conditional Keys in labels
  • Required when setting labels
labels[].value String Conditional Values in labels
  • Required when setting labels
taints[] Array Optional Manage schedulers to avoid using nodes in a particular pod.
taints[].key String Conditional Keys in taints
  • Required when setting taints
taints[].value String Optional Values in taints
  • Optional even when setting taints
taints[].effect String Conditional Scheduler management method
  • NoSchedule | PreferNoSchedule | NoExecute
  • Required when setting taints
serverRoleId String Optional ID to assign roles to node pool servers
zoneCode String Conditional Zone code of the node pool
  • Required for multi-zone (regional) clusters
  • Ignored in single-zone clusters
  • Check through the getZoneList action.
fabricCluster Object Conditional Fabric cluster information
  • Required when using server specifications that support Fabric clusters
fabricCluster.poolName String Conditional Fabric cluster pool name
  • Required when configuring Fabric cluster
fabricCluster.poolNo Integer Conditional Fabric cluster pool number
  • Required when configuring Fabric cluster

Request example

The request example is as follows:

curl --location 'https://nks.apigw.ntruss.com/vnks/v2/clusters/{uuid}/node-pool' \
--header 'x-ncp-apigw-timestamp: {timestamp}' \
--header 'x-ncp-iam-access-key: {access key}' \
--header 'x-ncp-apigw-signature-v2: {API gateway signature}' \
--data '{
"name": "np4",
"nodeCount": 2,
"softwareCode": "SW.VSVR.OS.LNX64.UBNTU.SVR22.WRKND.G003",
"serverSpecCode": "s2-g3",
"storageSize": 100,
"autoscale": {
"enabled": true,
"max": 2,
"min": 1
},
"labels": [
{
"key": "label_key",
"value": "value"
}
],
"taints": [
{
"key": "taints_key",
"value": "value",
"effect": "NoExecute"
}
]
}'

Response

This section describes the response format.

Response status codes

For information about the HTTP status codes common to all Ncloud Kubernetes Service APIs, see Ncloud Kubernetes Service response status
codes