-
Notifications
You must be signed in to change notification settings - Fork 177
Azure Container Repository Login Fails #3288
Copy link
Copy link
Open
Labels
help wantedHelp wantedHelp wantedkind/bugBugsBugsstatus/readyReady to be picked upReady to be picked up
Description
Context
Starting with az CLI v2.30, token persistence to accessTokens.json was deprecated. However, func still relies on this file to authenticate against ACR. As a result, we are hitting errors such as:
open Azure access tokens: no such file or directory
This breaks ACR authentication flows that previously worked without any user-side changes.
Possible Approaches
- Call
az acr login --expose-tokenoraz account get-access-tokento get a fresh token from az CLI whenever we want to access an Azure Container Repository - Use the Azure SDK for Go to get default credentials and a fresh token (this would delegate authentication to supported mechanisms (including, but not limited to
azCLI)
Related Work
I implemented a fix to validate the second approach here: stackbuilders#2
The PR avoids relying on accessTokens.json and instead fetches a fresh token using the SDK.
Happy to open a PR here and adjust it to better align with the project’s preferred direction.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
help wantedHelp wantedHelp wantedkind/bugBugsBugsstatus/readyReady to be picked upReady to be picked up