-
Notifications
You must be signed in to change notification settings - Fork 41
OADP-6675: Update Azure registry configuration for workload identity support #350
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: oadp-dev
Are you sure you want to change the base?
Conversation
- Replace deprecated SPN_* environment variables with CREDENTIALS_* format - Add support for Azure credentials type from secret - Update secret key references to match OADP operator changes This change is required to work with the updated OADP operator that now supports Azure workload identity authentication for the image registry. Depends on: OADP operator changes for Azure workload identity support 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
|
Skipping CI for Draft Pull Request. |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: kaovilai The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
@kaovilai: This pull request references OADP-6675 which is a valid jira issue. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository. |
|
Issues go stale after 90d of inactivity. Mark the issue as fresh by commenting If this issue is safe to close now please do so with /lifecycle stale |
|
Important Review skippedAuto reviews are limited based on label configuration. 🚫 Review skipped — only excluded labels are configured. (1)
Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the ✨ Finishing touches🧪 Generate unit tests (beta)
Comment |
Why the changes were made
This PR updates the Azure registry configuration to support workload identity authentication. These changes are required to work with the updated OADP operator that now supports Azure workload identity for the image registry component.
Without these changes, the openshift-velero-plugin cannot consume the new secret format created by the OADP operator when using Azure workload identity.
How to test the changes made
Prerequisites
Testing Steps
Deploy OADP operator with Azure workload identity support from PR #1952
Build and deploy this version of openshift-velero-plugin:
Verification Points
Technical Details
Azure Workload Identity Environment Setup
The OADP operator injects Azure workload identity environment variables into the Velero container through a secret (
azure-workload-identity-env). This secret contains:AZURE_CLIENT_ID: The managed identity client IDAZURE_TENANT_ID: The Azure tenant IDAZURE_FEDERATED_TOKEN_FILE: Path to the federated token (/var/run/secrets/openshift/serviceaccount/token)These environment variables are injected into the Velero deployment using
envFrom(see oadp-operatorinternal/controller/velero.go:642-655), ensuring they're available to both Velero and its plugins.Registry Authentication with Workload Identity
The registry component (docker-distribution) supports Azure AD authentication through the
default_credentialstype. When this type is set in the registry secret, the Azure storage driver:DefaultAzureCredentialThe plugin doesn't need to explicitly handle
AZURE_FEDERATED_TOKEN_FILEbecause:Changes Summary
SPN_*environment variable constants withCREDENTIALS_*formatgetAzureRegistryEnvVars()to reference new secret keys matching OADP operatorcredentials_typefield from secretObjectStorageinstead ofStorageType.ObjectStorage)Dependencies
This PR depends on: openshift/oadp-operator#1952
Both PRs must be merged together for Azure workload identity support to function properly. The OADP operator PR handles creating and injecting the workload identity environment variables, while this PR ensures the plugin correctly consumes the new secret format.
🤖 Generated with Claude Code