clusters_node_pools
Creates, updates, deletes, gets or lists a clusters_node_pools
resource.
Overview
Name | clusters_node_pools |
Type | Resource |
Id | digitalocean.kubernetes.clusters_node_pools |
Fields
Name | Datatype | Description |
---|---|---|
column_anon | `` |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
kubernetes_get_node_pool | SELECT | cluster_id, node_pool_id | To show information about a specific node pool in a Kubernetes cluster, send a GET request to /v2/kubernetes/clusters/$K8S_CLUSTER_ID/node_pools/$NODE_POOL_ID . |
kubernetes_list_node_pools | SELECT | cluster_id | To list all of the node pools in a Kubernetes clusters, send a GET request to /v2/kubernetes/clusters/$K8S_CLUSTER_ID/node_pools . |
kubernetes_add_node_pool | INSERT | cluster_id | To add an additional node pool to a Kubernetes clusters, send a POST request to /v2/kubernetes/clusters/$K8S_CLUSTER_ID/node_pools with the following attributes. |
kubernetes_delete_node_pool | DELETE | cluster_id, node_pool_id | To delete a node pool, send a DELETE request to /v2/kubernetes/clusters/$K8S_CLUSTER_ID/node_pools/$NODE_POOL_ID . A 204 status code with no body will be returned in response to a successful request. Nodes in the pool will subsequently be drained and deleted. |
kubernetes_recycle_node_pool | EXEC | cluster_id, node_pool_id | The endpoint has been deprecated. Please use the DELETE /v2/kubernetes/clusters/$K8S_CLUSTER_ID/node_pools/$NODE_POOL_ID/nodes/$NODE_ID method instead. |
kubernetes_update_node_pool | EXEC | cluster_id, node_pool_id | To update the name of a node pool, edit the tags applied to it, or adjust its number of nodes, send a PUT request to /v2/kubernetes/clusters/$K8S_CLUSTER_ID/node_pools/$NODE_POOL_ID with the following attributes. |
SELECT
examples
To list all of the node pools in a Kubernetes clusters, send a GET request to /v2/kubernetes/clusters/$K8S_CLUSTER_ID/node_pools
.
SELECT
column_anon
FROM digitalocean.kubernetes.clusters_node_pools
WHERE cluster_id = '{{ cluster_id }}';
INSERT
example
Use the following StackQL query and manifest file to create a new clusters_node_pools
resource.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO digitalocean.kubernetes.clusters_node_pools (
data__size,
data__name,
data__count,
data__tags,
data__labels,
data__taints,
data__auto_scale,
data__min_nodes,
data__max_nodes,
cluster_id
)
SELECT
'{{ size }}',
'{{ name }}',
'{{ count }}',
'{{ tags }}',
'{{ labels }}',
'{{ taints }}',
'{{ auto_scale }}',
'{{ min_nodes }}',
'{{ max_nodes }}',
'{{ cluster_id }}'
;
/*+ create */
INSERT INTO digitalocean.kubernetes.clusters_node_pools (
cluster_id
)
SELECT
'{{ cluster_id }}'
;
- name: clusters_node_pools
props:
- name: cluster_id
value: string
- name: size
value: string
- name: name
value: string
- name: count
value: integer
- name: tags
value: array
- name: labels
value: object
- name: taints
value: array
props:
- name: key
value: string
- name: value
value: string
- name: effect
value: string
- name: auto_scale
value: boolean
- name: min_nodes
value: integer
- name: max_nodes
value: integer
DELETE
example
Deletes the specified clusters_node_pools
resource.
/*+ delete */
DELETE FROM digitalocean.kubernetes.clusters_node_pools
WHERE cluster_id = '{{ cluster_id }}'
AND node_pool_id = '{{ node_pool_id }}';