Configuring and Deleting a Custom Registry from Karbon
By default, Karbon does not add additional container image registries to Kubernetes clusters. To use your own images for container deployment, add a custom registry to Karbon and configure custom registry access for the intended Kubernetes clusters.
Procedure
-
Add the custom registry to Karbon. Replace registry-name with name of the registry, replace registry-url with the URL of the registry, and replace registry-port with the port number to your custom registry. If the registry is certificate-based, replace cert-filepath with the file path to the certificate. Omit the cert-filepath parameter for HTTP-based registries.
nutanix@pcvm$ ./karbon/karbonctl registry add --name registry-name \--url registry-url --port registry-port --cert-file cert-filepath
-
Check for custom registries known to Karbon.
nutanix@pcvm$ ./karbon/karbonctl registry list
- Add the custom registry to a Kubernetes cluster. Replace cluster-name with the name of the Kubernetes cluster. Replace registry-name with the name of the registry as in step 1.
nutanix@pcvm$ ./karbon/karbonctl cluster registry add --cluster-name \ cluster-name --registry-name registry-name
- Confirm that Karbon and the Kubernetes cluster have access to the custom registry. Replace cluster-name with the name of the Kubernetes cluster.
./karbonctl cluster registry list --cluster-name cluster-name
Deleting a custom registry
Delete access to a custom registry before removing the registry from Karbon. Follow the steps as indicated:
Procedure
-
Delete access to a custom registry from your Kubenetes cluster. Replace cluster-name with the name of the Kubernetes cluster, and replace the registry-name with the name of the target registry.
nutanix@pcvm$ ./karbon/karbonctl cluster registry delete --cluster-name cluster-name \--registry-name registry-name
- Note: Before deleting the registry, revoke registry access from all clusters.
Delete a custom registry from Karbon. Replace the registry-name with the name of the target registry.
-
nutanix@pcvm$ ./karbon/karbonctl registry delete --registry-name registry-name
Portal Link: https://portal.nutanix.com/page/documents/details?targetId=Karbon-v2_1:kar-karbon-registry-custom-t.html