Skip to content

Commit 10226a4

Browse files
committed
docs(argocd-image-updater): Fix authScripts Azure Workload Identity example
Signed-off-by: Lyqed <98341862+Lyqed@users.noreply.github.com> Bump chart version Signed-off-by: Lyqed <98341862+Lyqed@users.noreply.github.com> run helm-docs.sh Signed-off-by: Lyqed <98341862+Lyqed@users.noreply.github.com>
1 parent 40804ba commit 10226a4

File tree

2 files changed

+24
-15
lines changed

2 files changed

+24
-15
lines changed

charts/argocd-image-updater/Chart.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ apiVersion: v2
22
name: argocd-image-updater
33
description: A Helm chart for Argo CD Image Updater, a tool to automatically update the container images of Kubernetes workloads which are managed by Argo CD
44
type: application
5-
version: 1.1.0
5+
version: 1.1.1
66
appVersion: v1.1.0
77
home: https://github.com/argoproj-labs/argocd-image-updater
88
icon: https://argocd-image-updater.readthedocs.io/en/stable/assets/logo.png
@@ -19,4 +19,4 @@ annotations:
1919
url: https://argoproj.github.io/argo-helm/pgp_keys.asc
2020
artifacthub.io/changes: |
2121
- kind: changed
22-
description: Bump argocd-image-updater to v1.1.0
22+
description: Bump argocd-image-updater to v1.1.1

charts/argocd-image-updater/values.yaml

Lines changed: 22 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -205,22 +205,31 @@ authScripts:
205205
# -- Name of the authentication scripts ConfigMap
206206
name: argocd-image-updater-authscripts
207207
# -- Map of key-value pairs where the key consists of the name of the script and the value the contents.
208-
## Expect the script to output Docker credentials in the form: <username>:<password>
208+
## Expect the script to output Docker credentials in the form: `<username>:<password>`
209209
## Authentication scripts can be used for various cloud providers like ECR or Azure Workload Identity.
210-
## For Azure Workload Identity, you can place your authentication script here to handle token acquisition.
210+
## For Azure Workload Identity, ensure `serviceAccount.annotations` includes `azure.workload.identity/client-id`
211+
## and `podLabels` includes `azure.workload.identity/use: "true"`.
212+
## Also set `extraEnv` with `ACR_NAME` pointing to your registry (e.g. `myregistry.azurecr.io`).
211213
scripts: {}
212-
# auth1.sh: |
213-
# #!/bin/sh
214-
# echo "auth script 1 here"
215-
# auth2.sh: |
216-
# #!/bin/sh
217-
# echo "auth script 2 here"
218214
# azure-workload-identity.sh: |
219-
# #!/bin:sh
220-
# # Example script for Azure Workload Identity.
221-
# # This script would typically use environment variables set by the workload identity
222-
# # to acquire an Azure AD token and authenticate with Azure Container Registry (ACR).
223-
# # It should output the Docker username and password on stdout, e.g., '00000000-0000-0000-0000-000000000000:<token>'
215+
# #!/bin/sh
216+
# set -eo pipefail
217+
# TOKEN=$(cat "$AZURE_FEDERATED_TOKEN_FILE")
218+
# ACCESS_TOKEN=$(curl -s -X POST \
219+
# "https://login.microsoftonline.com/${AZURE_TENANT_ID}/oauth2/v2.0/token" \
220+
# -d "grant_type=client_credentials" \
221+
# -d "client_id=${AZURE_CLIENT_ID}" \
222+
# -d "client_assertion_type=urn:ietf:params:oauth:client-assertion-type:jwt-bearer" \
223+
# -d "client_assertion=${TOKEN}" \
224+
# -d "scope=https://management.azure.com/.default" \
225+
# | jq -r '.access_token')
226+
# REFRESH_TOKEN=$(curl -s -X POST \
227+
# "https://${ACR_NAME}/oauth2/exchange" \
228+
# -d "grant_type=access_token" \
229+
# -d "service=${ACR_NAME}" \
230+
# -d "access_token=${ACCESS_TOKEN}" \
231+
# | jq -r '.refresh_token')
232+
# echo "00000000-0000-0000-0000-000000000000:${REFRESH_TOKEN}"
224233

225234
serviceAccount:
226235
# -- Specifies whether a service account should be created

0 commit comments

Comments
 (0)