Commit cc23fef0 authored by Lucas Charles's avatar Lucas Charles Committed by Amy Qualls (currently half-days after surgery)

Chore: Align cluster service token docs with code

Internally we set the service account name to `gitlab`
(see https://gitlab.com/gitlab-org/gitlab/-/blob/f5f4e40cbd90b4479b5307eebf1715a92e2944aa/app/services/clusters/kubernetes.rb#L5-8).
We should align the docs to the naming scheme used internally.
parent 38ef3273
......@@ -206,7 +206,7 @@ To add a Kubernetes cluster to your project, group, or instance:
apiVersion: v1
kind: ServiceAccount
metadata:
name: gitlab-admin
name: gitlab
namespace: kube-system
---
apiVersion: rbac.authorization.k8s.io/v1beta1
......@@ -219,7 +219,7 @@ To add a Kubernetes cluster to your project, group, or instance:
name: cluster-admin
subjects:
- kind: ServiceAccount
name: gitlab-admin
name: gitlab
namespace: kube-system
```
......@@ -245,23 +245,23 @@ To add a Kubernetes cluster to your project, group, or instance:
Output:
```shell
serviceaccount "gitlab-admin" created
serviceaccount "gitlab" created
clusterrolebinding "gitlab-admin" created
```
1. Retrieve the token for the `gitlab-admin` service account:
1. Retrieve the token for the `gitlab` service account:
```shell
kubectl -n kube-system describe secret $(kubectl -n kube-system get secret | grep gitlab-admin | awk '{print $1}')
kubectl -n kube-system describe secret $(kubectl -n kube-system get secret | grep gitlab | awk '{print $1}')
```
Copy the `<authentication_token>` value from the output:
```yaml
Name: gitlab-admin-token-b5zv4
Name: gitlab-token-b5zv4
Namespace: kube-system
Labels: <none>
Annotations: kubernetes.io/service-account.name=gitlab-admin
Annotations: kubernetes.io/service-account.name=gitlab
kubernetes.io/service-account.uid=bcfe66ac-39be-11e8-97e8-026dce96b6e8
Type: kubernetes.io/service-account-token
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment