Skip to content

Commit 93fd627

Browse files
committed
OCIRepo docs: auto-login setup details
Signed-off-by: Sunny <[email protected]>
1 parent 478a182 commit 93fd627

File tree

1 file changed

+23
-15
lines changed

1 file changed

+23
-15
lines changed

docs/spec/v1beta2/ocirepositories.md

Lines changed: 23 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -120,11 +120,14 @@ If you do not specify `.spec.provider`, it defaults to `generic`.
120120

121121
#### AWS
122122

123-
The `aws` provider can be used when the source-controller service account
124-
is associated with an AWS IAM Role using IRSA that grants read-only access to ECR.
123+
The `aws` provider can be used to automatically log into ECR using the EKS
124+
worker node IAM role or IAM Role for Service Accounts (IRSA).
125125

126-
To enable access to ECR, add the following patch to your bootstrap repository,
127-
in the `flux-system/kustomization.yaml` file:
126+
When the worker node IAM role has access to ECR, source-controller running on it
127+
will also have access to ECR.
128+
129+
When using IRSA to enable access to ECR, add the following patch to your
130+
bootstrap repository, in the `flux-system/kustomization.yaml` file:
128131

129132
```yaml
130133
apiVersion: kustomize.config.k8s.io/v1beta1
@@ -150,11 +153,14 @@ to the IAM role when using IRSA.
150153

151154
#### Azure
152155

153-
The `azure` provider can be used when the source-controller pods are associated
154-
with an Azure AAD Pod Identity that grants read-only access to ACR.
156+
The `azure` provider can be used to automatically log into ACR using kubelet
157+
managed identity or Azure Active Directory pod-managed identity (aad-pod-identity).
158+
159+
When the kubelet managed identity has access to ACR, source-controller running
160+
on it will also have access to ACR.
155161

156-
To enable access to ACR, add the following patch to your bootstrap repository,
157-
in the `flux-system/kustomization.yaml` file:
162+
When using aad-pod-identity to enable access to ECR, add the following patch to
163+
your bootstrap repository, in the `flux-system/kustomization.yaml` file:
158164

159165
```yaml
160166
apiVersion: kustomize.config.k8s.io/v1beta1
@@ -172,7 +178,7 @@ patches:
172178
name: source-controller
173179
```
174180

175-
When using managed identity on an AKS cluster, AAD Pod Identity
181+
When using pod-managed identity on an AKS cluster, AAD Pod Identity
176182
has to be used to give the `source-controller` pod access to the ACR.
177183
To do this, you have to install `aad-pod-identity` on your cluster, create a managed identity
178184
that has access to the container registry (this can also be the Kubelet identity
@@ -185,13 +191,15 @@ if you want to use AKS pod-managed identities add-on that is in preview.
185191

186192
#### GCP
187193

188-
The `gcp` provider can be used when the source-controller service account
189-
is associated with a GCP IAM Role using Workload Identity that grants
190-
read-only access to Artifact Registry.
194+
The `gcp` provider can be used to automatically log into GCR or Artifact
195+
Registry using OAuth scopes or Workload Identity.
196+
197+
When the GKE nodes have the appropriate OAuth scope for accessing GCR and
198+
Artifact Registry, source-controller running on it will also have access to them.
191199

192-
To enable access to Google Artifact Registry or GCR,
193-
add the following patch to your bootstrap repository,
194-
in the `flux-system/kustomization.yaml` file:
200+
When using Workload Identity to enable access to GCR or Artifact Registry, add
201+
the following patch to your bootstrap repository, in the
202+
`flux-system/kustomization.yaml` file:
195203

196204
```yaml
197205
apiVersion: kustomize.config.k8s.io/v1beta1

0 commit comments

Comments
 (0)