Configure host names for cluster machines

TechPreview Available since 2.24.0

You can enable custom host names for cluster machines so that any machine host name in a particular management cluster and its managed clusters matches the related Machine object name. For example, instead of the default kaas-node-<UID>, a machine host name will be master-0. The custom naming format is more convenient and easier to operate with.


After you enable custom host names on an existing management cluster, names of all newly deployed machines in this cluster and its managed clusters will match machine host names. Existing host names will remain the same.

If you are going to clean up a management cluster with this feature enabled after cluster deployment, make sure to manually delete machines with existing non-custom host names before cluster cleanup to prevent cleanup failure. For details, see Remove a management cluster.

You can enable custom host names during management cluster bootstrap during initial cluster configuration. For details, see Deployment Guide. To enable the feature on an existing cluster, see the procedure below.

To enable custom host names on an existing management cluster:

  1. Open the Cluster object of the management cluster for editing:

    kubectl edit cluster <mgmtClusterName>
  2. In the spec.providerSpec.value.kaas.regional section of the required region, find the required provider name under helmReleases and add customHostnamesEnabled: true under values.config.

    For example, for the bare metal provider:

     - helmReleases:
       - name: baremetal-provider
             allInOneAllowed: false
             customHostnamesEnabled: true
             internalLoadBalancers: false

    The configuration applies in several minutes after the <providerName>-provider-* Pods restart automatically.

  3. Verify that customHostnames is present in the provider ConfigMap:

    kubectl -n kaas get configmap provider-config-<providerName> -o=yaml | grep customHostnames
    kubectl -n kaas get configmap provider-config-<providerName>-<regionName> -o=yaml | grep customHostnames