How to Retrieve the Cluster Configuration for Vultr Kubernetes Engine Cluster

Updated on December 9, 2024

Retrieving a Vultr Kubernetes Engine (VKE) cluster configuration allows you to access essential details about your Kubernetes cluster, including API endpoints, authentication credentials, and resource specifications. This process is crucial for managing and interacting with your VKE cluster effectively. Vultr Kubernetes Engine provides straightforward methods to retrieve these configurations, ensuring you have the necessary information to operate and scale your VKE cluster efficiently.

Follow this guide to retrieve the VKE cluster configuration from your Vultr account using the Vultr Customer Portal, API, or CLI.

  • Vultr Customer Portal
  • Vultr API
  • Vultr CLI
  1. Navigate to Products and click Kubernetes.

  2. Click your target VKE cluster to open its management page.

  3. Click Download Configuration.

    Button to download the Kubernetes cluster configuration

  1. Send a GET request to the List Kubernetes Clusters endpoint and note the target VKE cluster's ID.

    console
    $ curl -X GET "https://api.vultr.com/v2/kubernetes/clusters" \
        -H "Authorization: Bearer ${VULTR_API_KEY}" \
        -H "Content-Type: application/json"
    
  2. Send a GET request to the Kubernetes Clusters Config endpoint to get the config file for the target VKE cluster.

    console
    $ curl -X GET "https://api.vultr.com/v2/kubernetes/clusters/<cluster-id>/config" \
        -H "Authorization: Bearer ${VULTR_API_KEY}" \
        -H "Content-Type: application/json" \
        -o kubeconfig.yaml
    
  1. List the available VKE clusters in your Vultr account and note the target VKE cluster's ID.

    console
    $ vultr-cli kubernetes list --summarize
    
  2. Get the VKE cluster configuration file.

    console
    $ vultr-cli kubernetes config <cluster-id> --output yaml