Configure a Wildcard Domain for your Proxied Cluster
Wildcard domains are helpful in multi-cluster environments. When you set up a wildcard domain, every time you attach an additional network-restricted cluster through a proxy, the DKP UI pre-fills a domain for the cluster automatically.
After you set up a wildcard domain in the kommander.yaml
as explained in the following section, DKP will suggest domains for attached clusters automatically based on the wildcard domain + the name of the cluster, for example:
Wildcard Domain | Cluster Name | Cluster Domain |
---|---|---|
*.example.com | development.cluster | development.cluster.example.com |
*.example.com | janedoe | janedoe.example.com |
You can override the domain by overwriting the suggested domain in the UI.
Set up a Wildcard Domain
Open the
kommander.yaml
file:If you have not installed the Kommander component yet, initialize the configuration file, so you can edit it in the following steps.
WARNING: Initialize this file only ONCE, otherwise you will overwrite previous customizations.If you have installed the Kommander component already, open the existing
kommander.yaml
with the editor of your choice.
Adjust the
apps
section of yourkommander.yaml
file to include these values:CODEapiVersion: config.kommander.mesosphere.io/v1alpha1 kind: Installation apps: [...] kubetunnel: enabled: true values: | proxiedAccess: clusterDomainWildcard: "*.example.com"
Use the configuration file to install or update the Kommander component:
CODEdkp install kommander --installer-config kommander.yaml --kubeconfig=${CLUSTER_NAME}.conf
Whenever you attach a network-restricted cluster, the UI will suggest a new domain based on the wildcard domain and cluster name.
Configure a DNS Record or DNS Service
The clusters will not be available through the established domain until you manually create a DNS record or enable external-dns
to automatically manage the creation of records.
D2iQ recommends enabling the External DNS service to manage your records automatically. However, you can choose to create your records manually.