Manage your CMK Clusters
Creating a New Cluster
- CLI
- UI
- Terraform
You can create clusters using the kubernetes clusters create
command. Please use the -help
flag for an exhaustive list of options.
crusoe kubernetes clusters create \
--name my-first-cluster \
--cluster-version 1.30 \
--location us-east1-a \
--subnet-id 6f8e2a1b-7b1d-4c8e-a9f2-8e3d6c1f2a0c
--add-ons "nvidia_gpu_operator,nvidia_network_operator,crusoe_csi"
You may list the Kubernetes versions available for cluster creation by using the 'kubernetes clusters list-versions' command. Specifying an unqualified version (e.g. 1.30) when creating a cluster will provision the latest stable patch version associated with the minor version.
In order to create a CMK cluster via the cloud console:
- Visit the Crusoe Cloud console
- Click the "Orchestration" tab in the left nav
- Click the "Create Cluster" button
- Follow the UI flow to input all required elements
- Optional selections include specifying the Service and Pod network CIDRs for Cilium and selecting one or more add-ons to deploy into the cluster
- Click the "Create" button
You can use the crusoe_kubernetes_cluster
resource to create a new Kubernetes cluster using Terraform.
terraform {
required_providers {
crusoe = {
source = "crusoecloud/crusoe"
}
}
}
locals {
my_ssh_key = file("~/.ssh/id_ed25519.pub") # replace with path to your public SSH key if different
}
resource "crusoe_kubernetes_cluster" "my_first_cluster" {
name = "tf-cluster"
version = "1.30"
location = "us-east1-a"
subnet_id = "6f8e2a1b-7b1d-4c8e-a9f2-8e3d6c1f2a0c"
add_ons = "nvidia_gpu_operator,nvidia_network_operator,crusoe_csi"
}
Viewing Existing Clusters
- CLI
- UI
Use the kubernetes clusters list
command to list all existing clusters. You can also use the `kubernetes clusters get' command to retrieve details for a specific cluster.
crusoe kubernetes clusters get <name/id>
To view a list of clusters via the Crusoe Cloud console:
- Visit the Crusoe Cloud console
- Click the "Orchestration" tab in the left nav
- Select the cluster you want credentials for
- Click the "Generate Kubeconfig" button on the top right
- Your kubeconfig will be downloaded
Get cluster credentials
- CLI
- UI
Use the `kubernetes clusters get-credentials' command to retrieve credentials for a specific cluster.
crusoe kubernetes clusters get-credentials <name/id>
By default, credentials will be stored in a file named ~/.kube/config
. You may alter the path credentials are stored at by using the --kubeconfig-path
flag. If you have existing configs stored in the same path, the new cluster kubeconfig will be appended to the end and set as the current context.
Admin users can retrieve your cluster admin kubeconfig through the following steps:
- Visit the Crusoe Cloud console
- Click the "Orchestration" tab in the left nav
- Select the cluster you want credentials for
- Click the "Generate Kubeconfig" button on the top right
- Your kubeconfig will be downloaded
Delete a cluster
Note that you must delete all nodepools in the cluster before deleting the cluster.
- CLI
- UI
- Terraform
You can delete clusters by using the kubernetes clusters delete
command and specifying either the name of ID of the cluster you want to delete.
crusoe kubernetes clusters delete <name/id>
In order to create a CMK cluster via the cloud console:
- Visit the Crusoe Cloud console
- Click the "Orchestration" tab in the left nav
- Select the cluster you want to delete
- Make sure that the cluster has no nodepools associated with it. If it does, delete them.
- Click the "Delete" icon associated with the cluster
Running a terraform destroy
command provided by the Terraform CLI tool will delete the cluster and associated resources.
If you are having issues creating or deleting clusters, please contact support.