All URIs are relative to https://api.vultr.com/v2
Method | HTTP request | Description |
---|---|---|
create_kubernetes_cluster | POST /kubernetes/clusters | Create Kubernetes Cluster |
create_nodepools | POST /kubernetes/clusters/{vke-id}/node-pools | Create NodePool |
delete_kubernetes_cluster | DELETE /kubernetes/clusters/{vke-id} | Delete Kubernetes Cluster |
delete_kubernetes_cluster_vke_id_delete_with_linked_resources | DELETE /kubernetes/clusters/{vke-id}/delete-with-linked-resources | Delete VKE Cluster and All Related Resources |
delete_nodepool | DELETE /kubernetes/clusters/{vke-id}/node-pools/{nodepool-id} | Delete Nodepool |
delete_nodepool_instance | DELETE /kubernetes/clusters/{vke-id}/node-pools/{nodepool-id}/nodes/{node-id} | Delete NodePool Instance |
get_kubernetes_available_upgrades | GET /kubernetes/clusters/{vke-id}/available-upgrades | Get Kubernetes Available Upgrades |
get_kubernetes_clusters | GET /kubernetes/clusters/{vke-id} | Get Kubernetes Cluster |
get_kubernetes_clusters_config | GET /kubernetes/clusters/{vke-id}/config | Get Kubernetes Cluster Kubeconfig |
get_kubernetes_resources | GET /kubernetes/clusters/{vke-id}/resources | Get Kubernetes Resources |
get_kubernetes_versions | GET /kubernetes/versions | Get Kubernetes Versions |
get_nodepool | GET /kubernetes/clusters/{vke-id}/node-pools/{nodepool-id} | Get NodePool |
get_nodepools | GET /kubernetes/clusters/{vke-id}/node-pools | List NodePools |
list_kubernetes_clusters | GET /kubernetes/clusters | List all Kubernetes Clusters |
recycle_nodepool_instance | POST /kubernetes/clusters/{vke-id}/node-pools/{nodepool-id}/nodes/{node-id}/recycle | Recycle a NodePool Instance |
start_kubernetes_cluster_upgrade | POST /kubernetes/clusters/{vke-id}/upgrades | Start Kubernetes Cluster Upgrade |
update_kubernetes_cluster | PUT /kubernetes/clusters/{vke-id} | Update Kubernetes Cluster |
update_nodepool | PATCH /kubernetes/clusters/{vke-id}/node-pools/{nodepool-id} | Update Nodepool |
create_kubernetes_cluster(opts)
Create Kubernetes Cluster
Create Kubernetes Cluster
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
opts = {
create_kubernetes_cluster_request: VultrRuby::CreateKubernetesClusterRequest.new({region: 'region_example', version: 'version_example'}) # CreateKubernetesClusterRequest | Request Body
}
begin
# Create Kubernetes Cluster
result = api_instance.create_kubernetes_cluster(opts)
p result
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->create_kubernetes_cluster: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> create_kubernetes_cluster_with_http_info(opts)
begin
# Create Kubernetes Cluster
data, status_code, headers = api_instance.create_kubernetes_cluster_with_http_info(opts)
p status_code # => 2xx
p headers # => { ... }
p data # => <CreateKubernetesCluster201Response>
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->create_kubernetes_cluster_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
create_kubernetes_cluster_request | CreateKubernetesClusterRequest | Request Body | [optional] |
CreateKubernetesCluster201Response
[API Key](../README.md#API Key)
- Content-Type: application/json
- Accept: application/json
create_nodepools(vke_id, opts)
Create NodePool
Create NodePool for a Existing Kubernetes Cluster
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
vke_id = 'vke_id_example' # String | The [VKE ID](#operation/list-kubernetes-clusters).
opts = {
create_nodepools_request: VultrRuby::CreateNodepoolsRequest.new({node_quantity: 37, label: 'label_example', plan: 'plan_example'}) # CreateNodepoolsRequest | Request Body
}
begin
# Create NodePool
result = api_instance.create_nodepools(vke_id, opts)
p result
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->create_nodepools: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> create_nodepools_with_http_info(vke_id, opts)
begin
# Create NodePool
data, status_code, headers = api_instance.create_nodepools_with_http_info(vke_id, opts)
p status_code # => 2xx
p headers # => { ... }
p data # => <CreateNodepools201Response>
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->create_nodepools_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
vke_id | String | The VKE ID. | |
create_nodepools_request | CreateNodepoolsRequest | Request Body | [optional] |
[API Key](../README.md#API Key)
- Content-Type: application/json
- Accept: application/json
delete_kubernetes_cluster(vke_id)
Delete Kubernetes Cluster
Delete Kubernetes Cluster
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
vke_id = 'vke_id_example' # String | The [VKE ID](#operation/list-kubernetes-clusters).
begin
# Delete Kubernetes Cluster
api_instance.delete_kubernetes_cluster(vke_id)
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->delete_kubernetes_cluster: #{e}"
end
This returns an Array which contains the response data (nil
in this case), status code and headers.
<Array(nil, Integer, Hash)> delete_kubernetes_cluster_with_http_info(vke_id)
begin
# Delete Kubernetes Cluster
data, status_code, headers = api_instance.delete_kubernetes_cluster_with_http_info(vke_id)
p status_code # => 2xx
p headers # => { ... }
p data # => nil
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->delete_kubernetes_cluster_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
vke_id | String | The VKE ID. |
nil (empty response body)
[API Key](../README.md#API Key)
- Content-Type: Not defined
- Accept: Not defined
delete_kubernetes_cluster_vke_id_delete_with_linked_resources(vke_id)
Delete VKE Cluster and All Related Resources
Delete Kubernetes Cluster and all related resources.
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
vke_id = 'vke_id_example' # String |
begin
# Delete VKE Cluster and All Related Resources
api_instance.delete_kubernetes_cluster_vke_id_delete_with_linked_resources(vke_id)
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->delete_kubernetes_cluster_vke_id_delete_with_linked_resources: #{e}"
end
This returns an Array which contains the response data (nil
in this case), status code and headers.
<Array(nil, Integer, Hash)> delete_kubernetes_cluster_vke_id_delete_with_linked_resources_with_http_info(vke_id)
begin
# Delete VKE Cluster and All Related Resources
data, status_code, headers = api_instance.delete_kubernetes_cluster_vke_id_delete_with_linked_resources_with_http_info(vke_id)
p status_code # => 2xx
p headers # => { ... }
p data # => nil
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->delete_kubernetes_cluster_vke_id_delete_with_linked_resources_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
vke_id | String |
nil (empty response body)
[API Key](../README.md#API Key)
- Content-Type: Not defined
- Accept: Not defined
delete_nodepool(vke_id, nodepool_id)
Delete Nodepool
Delete a NodePool from a Kubernetes Cluster
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
vke_id = 'vke_id_example' # String | The [VKE ID](#operation/list-kubernetes-clusters).
nodepool_id = 'nodepool_id_example' # String | The [NodePool ID](#operation/get-nodepools).
begin
# Delete Nodepool
api_instance.delete_nodepool(vke_id, nodepool_id)
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->delete_nodepool: #{e}"
end
This returns an Array which contains the response data (nil
in this case), status code and headers.
<Array(nil, Integer, Hash)> delete_nodepool_with_http_info(vke_id, nodepool_id)
begin
# Delete Nodepool
data, status_code, headers = api_instance.delete_nodepool_with_http_info(vke_id, nodepool_id)
p status_code # => 2xx
p headers # => { ... }
p data # => nil
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->delete_nodepool_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
vke_id | String | The VKE ID. | |
nodepool_id | String | The NodePool ID. |
nil (empty response body)
[API Key](../README.md#API Key)
- Content-Type: Not defined
- Accept: Not defined
delete_nodepool_instance(vke_id, nodepool_id, node_id)
Delete NodePool Instance
Delete a single nodepool instance from a given Nodepool
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
vke_id = 'vke_id_example' # String | The [VKE ID](#operation/list-kubernetes-clusters).
nodepool_id = 'nodepool_id_example' # String | The [NodePool ID](#operation/get-nodepools).
node_id = 'node_id_example' # String | The [Instance ID](#operation/list-instances).
begin
# Delete NodePool Instance
api_instance.delete_nodepool_instance(vke_id, nodepool_id, node_id)
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->delete_nodepool_instance: #{e}"
end
This returns an Array which contains the response data (nil
in this case), status code and headers.
<Array(nil, Integer, Hash)> delete_nodepool_instance_with_http_info(vke_id, nodepool_id, node_id)
begin
# Delete NodePool Instance
data, status_code, headers = api_instance.delete_nodepool_instance_with_http_info(vke_id, nodepool_id, node_id)
p status_code # => 2xx
p headers # => { ... }
p data # => nil
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->delete_nodepool_instance_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
vke_id | String | The VKE ID. | |
nodepool_id | String | The NodePool ID. | |
node_id | String | The Instance ID. |
nil (empty response body)
[API Key](../README.md#API Key)
- Content-Type: Not defined
- Accept: Not defined
get_kubernetes_available_upgrades(vke_id)
Get Kubernetes Available Upgrades
Get the available upgrades for the specified Kubernetes cluster.
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
vke_id = 'vke_id_example' # String | The [VKE ID](#operation/list-kubernetes-clusters).
begin
# Get Kubernetes Available Upgrades
result = api_instance.get_kubernetes_available_upgrades(vke_id)
p result
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->get_kubernetes_available_upgrades: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> get_kubernetes_available_upgrades_with_http_info(vke_id)
begin
# Get Kubernetes Available Upgrades
data, status_code, headers = api_instance.get_kubernetes_available_upgrades_with_http_info(vke_id)
p status_code # => 2xx
p headers # => { ... }
p data # => <GetKubernetesAvailableUpgrades200Response>
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->get_kubernetes_available_upgrades_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
vke_id | String | The VKE ID. |
GetKubernetesAvailableUpgrades200Response
[API Key](../README.md#API Key)
- Content-Type: Not defined
- Accept: application/json
get_kubernetes_clusters(vke_id)
Get Kubernetes Cluster
Get Kubernetes Cluster
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
vke_id = 'vke_id_example' # String | The [VKE ID](#operation/list-kubernetes-clusters).
begin
# Get Kubernetes Cluster
result = api_instance.get_kubernetes_clusters(vke_id)
p result
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->get_kubernetes_clusters: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> get_kubernetes_clusters_with_http_info(vke_id)
begin
# Get Kubernetes Cluster
data, status_code, headers = api_instance.get_kubernetes_clusters_with_http_info(vke_id)
p status_code # => 2xx
p headers # => { ... }
p data # => <CreateKubernetesCluster201Response>
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->get_kubernetes_clusters_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
vke_id | String | The VKE ID. |
CreateKubernetesCluster201Response
[API Key](../README.md#API Key)
- Content-Type: Not defined
- Accept: application/json
get_kubernetes_clusters_config(vke_id)
Get Kubernetes Cluster Kubeconfig
Get Kubernetes Cluster Kubeconfig
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
vke_id = 'vke_id_example' # String | The [VKE ID](#operation/list-kubernetes-clusters).
begin
# Get Kubernetes Cluster Kubeconfig
result = api_instance.get_kubernetes_clusters_config(vke_id)
p result
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->get_kubernetes_clusters_config: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> get_kubernetes_clusters_config_with_http_info(vke_id)
begin
# Get Kubernetes Cluster Kubeconfig
data, status_code, headers = api_instance.get_kubernetes_clusters_config_with_http_info(vke_id)
p status_code # => 2xx
p headers # => { ... }
p data # => <GetKubernetesClustersConfig200Response>
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->get_kubernetes_clusters_config_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
vke_id | String | The VKE ID. |
GetKubernetesClustersConfig200Response
[API Key](../README.md#API Key)
- Content-Type: Not defined
- Accept: application/json
get_kubernetes_resources(vke_id)
Get Kubernetes Resources
Get the block storage volumes and load balancers deployed by the specified Kubernetes cluster.
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
vke_id = 'vke_id_example' # String | The [VKE ID](#operation/list-kubernetes-clusters).
begin
# Get Kubernetes Resources
result = api_instance.get_kubernetes_resources(vke_id)
p result
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->get_kubernetes_resources: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> get_kubernetes_resources_with_http_info(vke_id)
begin
# Get Kubernetes Resources
data, status_code, headers = api_instance.get_kubernetes_resources_with_http_info(vke_id)
p status_code # => 2xx
p headers # => { ... }
p data # => <GetKubernetesResources200Response>
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->get_kubernetes_resources_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
vke_id | String | The VKE ID. |
GetKubernetesResources200Response
[API Key](../README.md#API Key)
- Content-Type: Not defined
- Accept: application/json
get_kubernetes_versions
Get Kubernetes Versions
Get a list of supported Kubernetes versions
require 'time'
require 'vultr_ruby'
api_instance = VultrRuby::KubernetesApi.new
begin
# Get Kubernetes Versions
result = api_instance.get_kubernetes_versions
p result
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->get_kubernetes_versions: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> get_kubernetes_versions_with_http_info
begin
# Get Kubernetes Versions
data, status_code, headers = api_instance.get_kubernetes_versions_with_http_info
p status_code # => 2xx
p headers # => { ... }
p data # => <GetKubernetesVersions200Response>
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->get_kubernetes_versions_with_http_info: #{e}"
end
This endpoint does not need any parameter.
GetKubernetesVersions200Response
No authorization required
- Content-Type: Not defined
- Accept: application/json
get_nodepool(vke_id, nodepool_id)
Get NodePool
Get Nodepool from a Kubernetes Cluster
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
vke_id = 'vke_id_example' # String | The [VKE ID](#operation/list-kubernetes-clusters).
nodepool_id = 'nodepool_id_example' # String | The [NodePool ID](#operation/get-nodepools).
begin
# Get NodePool
result = api_instance.get_nodepool(vke_id, nodepool_id)
p result
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->get_nodepool: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> get_nodepool_with_http_info(vke_id, nodepool_id)
begin
# Get NodePool
data, status_code, headers = api_instance.get_nodepool_with_http_info(vke_id, nodepool_id)
p status_code # => 2xx
p headers # => { ... }
p data # => <CreateNodepools201Response>
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->get_nodepool_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
vke_id | String | The VKE ID. | |
nodepool_id | String | The NodePool ID. |
[API Key](../README.md#API Key)
- Content-Type: Not defined
- Accept: application/json
get_nodepools(vke_id)
List NodePools
List all available NodePools on a Kubernetes Cluster
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
vke_id = 'vke_id_example' # String | The [VKE ID](#operation/list-kubernetes-clusters).
begin
# List NodePools
result = api_instance.get_nodepools(vke_id)
p result
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->get_nodepools: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> get_nodepools_with_http_info(vke_id)
begin
# List NodePools
data, status_code, headers = api_instance.get_nodepools_with_http_info(vke_id)
p status_code # => 2xx
p headers # => { ... }
p data # => <GetNodepools200Response>
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->get_nodepools_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
vke_id | String | The VKE ID. |
[API Key](../README.md#API Key)
- Content-Type: Not defined
- Accept: application/json
list_kubernetes_clusters
List all Kubernetes Clusters
List all Kubernetes clusters currently deployed
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
begin
# List all Kubernetes Clusters
result = api_instance.list_kubernetes_clusters
p result
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->list_kubernetes_clusters: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> list_kubernetes_clusters_with_http_info
begin
# List all Kubernetes Clusters
data, status_code, headers = api_instance.list_kubernetes_clusters_with_http_info
p status_code # => 2xx
p headers # => { ... }
p data # => <ListKubernetesClusters200Response>
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->list_kubernetes_clusters_with_http_info: #{e}"
end
This endpoint does not need any parameter.
ListKubernetesClusters200Response
[API Key](../README.md#API Key)
- Content-Type: Not defined
- Accept: application/json
recycle_nodepool_instance(vke_id, nodepool_id, node_id)
Recycle a NodePool Instance
Recycle a specific NodePool Instance
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
vke_id = 'vke_id_example' # String | The [VKE ID](#operation/list-kubernetes-clusters).
nodepool_id = 'nodepool_id_example' # String | The [NodePool ID](#operation/get-nodepools).
node_id = 'node_id_example' # String | Node ID
begin
# Recycle a NodePool Instance
api_instance.recycle_nodepool_instance(vke_id, nodepool_id, node_id)
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->recycle_nodepool_instance: #{e}"
end
This returns an Array which contains the response data (nil
in this case), status code and headers.
<Array(nil, Integer, Hash)> recycle_nodepool_instance_with_http_info(vke_id, nodepool_id, node_id)
begin
# Recycle a NodePool Instance
data, status_code, headers = api_instance.recycle_nodepool_instance_with_http_info(vke_id, nodepool_id, node_id)
p status_code # => 2xx
p headers # => { ... }
p data # => nil
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->recycle_nodepool_instance_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
vke_id | String | The VKE ID. | |
nodepool_id | String | The NodePool ID. | |
node_id | String | Node ID |
nil (empty response body)
[API Key](../README.md#API Key)
- Content-Type: Not defined
- Accept: Not defined
start_kubernetes_cluster_upgrade(vke_id, opts)
Start Kubernetes Cluster Upgrade
Start a Kubernetes cluster upgrade.
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
vke_id = 'vke_id_example' # String | The [VKE ID](#operation/list-kubernetes-clusters).
opts = {
start_kubernetes_cluster_upgrade_request: VultrRuby::StartKubernetesClusterUpgradeRequest.new({upgrade_version: 'upgrade_version_example'}) # StartKubernetesClusterUpgradeRequest | Request Body
}
begin
# Start Kubernetes Cluster Upgrade
api_instance.start_kubernetes_cluster_upgrade(vke_id, opts)
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->start_kubernetes_cluster_upgrade: #{e}"
end
This returns an Array which contains the response data (nil
in this case), status code and headers.
<Array(nil, Integer, Hash)> start_kubernetes_cluster_upgrade_with_http_info(vke_id, opts)
begin
# Start Kubernetes Cluster Upgrade
data, status_code, headers = api_instance.start_kubernetes_cluster_upgrade_with_http_info(vke_id, opts)
p status_code # => 2xx
p headers # => { ... }
p data # => nil
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->start_kubernetes_cluster_upgrade_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
vke_id | String | The VKE ID. | |
start_kubernetes_cluster_upgrade_request | StartKubernetesClusterUpgradeRequest | Request Body | [optional] |
nil (empty response body)
[API Key](../README.md#API Key)
- Content-Type: application/json
- Accept: Not defined
update_kubernetes_cluster(vke_id, opts)
Update Kubernetes Cluster
Update Kubernetes Cluster
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
vke_id = 'vke_id_example' # String | The [VKE ID](#operation/list-kubernetes-clusters).
opts = {
update_kubernetes_cluster_request: VultrRuby::UpdateKubernetesClusterRequest.new({label: 'label_example'}) # UpdateKubernetesClusterRequest | Request Body
}
begin
# Update Kubernetes Cluster
api_instance.update_kubernetes_cluster(vke_id, opts)
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->update_kubernetes_cluster: #{e}"
end
This returns an Array which contains the response data (nil
in this case), status code and headers.
<Array(nil, Integer, Hash)> update_kubernetes_cluster_with_http_info(vke_id, opts)
begin
# Update Kubernetes Cluster
data, status_code, headers = api_instance.update_kubernetes_cluster_with_http_info(vke_id, opts)
p status_code # => 2xx
p headers # => { ... }
p data # => nil
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->update_kubernetes_cluster_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
vke_id | String | The VKE ID. | |
update_kubernetes_cluster_request | UpdateKubernetesClusterRequest | Request Body | [optional] |
nil (empty response body)
[API Key](../README.md#API Key)
- Content-Type: application/json
- Accept: Not defined
update_nodepool(vke_id, nodepool_id, opts)
Update Nodepool
Update a Nodepool on a Kubernetes Cluster
require 'time'
require 'vultr_ruby'
# setup authorization
VultrRuby.configure do |config|
# Configure Bearer authorization: API Key
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = VultrRuby::KubernetesApi.new
vke_id = 'vke_id_example' # String | The [VKE ID](#operation/list-kubernetes-clusters).
nodepool_id = 'nodepool_id_example' # String | The [NodePool ID](#operation/get-nodepools).
opts = {
update_nodepool_request: VultrRuby::UpdateNodepoolRequest.new # UpdateNodepoolRequest | Request Body
}
begin
# Update Nodepool
result = api_instance.update_nodepool(vke_id, nodepool_id, opts)
p result
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->update_nodepool: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> update_nodepool_with_http_info(vke_id, nodepool_id, opts)
begin
# Update Nodepool
data, status_code, headers = api_instance.update_nodepool_with_http_info(vke_id, nodepool_id, opts)
p status_code # => 2xx
p headers # => { ... }
p data # => <CreateNodepools201Response>
rescue VultrRuby::ApiError => e
puts "Error when calling KubernetesApi->update_nodepool_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
vke_id | String | The VKE ID. | |
nodepool_id | String | The NodePool ID. | |
update_nodepool_request | UpdateNodepoolRequest | Request Body | [optional] |
[API Key](../README.md#API Key)
- Content-Type: application/json, application/xml
- Accept: application/json