From 26ceb90f43a9143be304a5e2100d664eb8d72220 Mon Sep 17 00:00:00 2001 From: timothy-spencer Date: Mon, 26 Apr 2021 11:49:17 -0700 Subject: [PATCH] add kube_cluster_name to try to make kubeconfig not have such a giant ugly name in it --- examples/chart/teleport-cluster/README.md | 1 + examples/chart/teleport-cluster/templates/config.yaml | 3 +++ examples/chart/teleport-cluster/values.yaml | 3 +++ 3 files changed, 7 insertions(+) diff --git a/examples/chart/teleport-cluster/README.md b/examples/chart/teleport-cluster/README.md index 841d81c2d47bc..cff024d743d21 100644 --- a/examples/chart/teleport-cluster/README.md +++ b/examples/chart/teleport-cluster/README.md @@ -35,6 +35,7 @@ Check https://goteleport.com/teleport/docs for more details. | Name | Description | Default | Required | |---------------------------|-----------------------------------------------------------------------------|--------------------------------------------------------|----------| | `clusterName` | Teleport cluster name (must be an FQDN) | | yes | +| `kubeClusterName` | kubernetes cluster name (used in the kubeconfig) | clusterName value | no | | `teleportVersionOverride` | Teleport version | Current stable version | no | | `image` | OSS Docker image | `quay.io/gravitational/teleport` | no | | `enterpriseImage` | Enterprise Docker image | `quay.io/gravitational/teleport-ent` | no | diff --git a/examples/chart/teleport-cluster/templates/config.yaml b/examples/chart/teleport-cluster/templates/config.yaml index f0e93db6a2593..f17c0cded9776 100644 --- a/examples/chart/teleport-cluster/templates/config.yaml +++ b/examples/chart/teleport-cluster/templates/config.yaml @@ -17,6 +17,9 @@ data: {{- end }} kubernetes_service: enabled: true +{{- if .Values.kubeClusterName }} + kube_cluster_name: {{ .Values.kubeClusterName }} +{{- end }} listen_addr: 0.0.0.0:3027 labels: {{- if .Values.labels }} diff --git a/examples/chart/teleport-cluster/values.yaml b/examples/chart/teleport-cluster/values.yaml index 2e70ba957c4d6..b8cde6b3a3b05 100644 --- a/examples/chart/teleport-cluster/values.yaml +++ b/examples/chart/teleport-cluster/values.yaml @@ -12,6 +12,9 @@ clusterName: # Values that you may need to change. ################################################## +# Name for this kubernetes cluster to be used by teleport users. +kubeClusterName: "" + # Version of teleport image, if different from appVersion in Chart.yaml. teleportVersionOverride: ""