You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<TabItemlabel="Bind policy to service account"value="federation">
18
+
<TabItemlabel="Assign Role to Kubernetes service account principal"value="federation">
19
19
20
20
You can also refer the official docs for [Workload Identity](https://cloud.google.com/kubernetes-engine/docs/how-to/workload-identity)
21
21
22
22
1. Enable workload identity
23
23
```bash
24
24
# The name of the GKE cluster mission control is being deployed to
25
25
export CLUSTER=<CLUSTER_NAME>
26
-
# the default namespace the mission-control helm chart uses
27
-
export NAMESPACE=mission-control
28
26
# GCP Project ID
29
27
export PROJECT_ID=gcp-project-id
30
28
# GCP Project Number
31
29
export PROJECT_NUMBER=gcp-project-number
32
30
# Location of GKE Cluster
33
31
LOCATION=us-east1
32
+
# the default namespace the mission-control helm chart uses
33
+
export NAMESPACE=mission-control
34
34
35
+
# enable workload identity in the host cluster
35
36
gcloud container clusters update $CLUSTER \
36
37
--location=$LOCATION \
37
-
--workload-pool=PROJECT_ID.svc.id.goog
38
+
--workload-pool=$PROJECT_ID.svc.id.goog
38
39
```
39
40
<p/>
40
41
41
42
2. Bind IAM Policy
42
43
43
-
The `$KSA_NAME` refers to the Kubernetes service account name. In our case, we need to bind to 3 service accounts: `mission-control-sa`, `canary-checker-sa` and `config-db-sa`
44
+
`$KSA_NAME` refers to the Kubernetes service account name. In our case, we need to bind to 3 service accounts: `mission-control-sa`, `canary-checker-sa` and `config-db-sa`
3. Create an IAM allow policy that gives the Kubernetes ServiceAccount access to impersonate the IAM service account:
103
+
4. Create an IAM allow policy that gives the Kubernetes service account access to impersonate the IAM service account:
91
104
92
105
The `$KSA_NAME` refers to the Kubernetes service account name. In our case, we need to bind to 3 service accounts: `mission-control`, `canary-checker` and `config-db`
93
106
94
107
```bash
95
-
gcloud iam service-accounts add-iam-policy-binding IAM_SA_NAME@IAM_SA_PROJECT_ID.iam.gserviceaccount.com \
0 commit comments