Azure / Azure/azure-sdk-for-python
Get ACR token from ContainerRegistryClient
- Lingua principale
- Python
- Stelle
- 5.6k
- Fork
- 3.4k
- Merge medio
- 2g
- PR unite (30g)
- 217
Descrizione
**Is your feature request related to a problem? Please describe.**
When you want to get an ACR refresh token like you would with
```bash
az acr login --name --expose-token --output tsv --query accessToken
```
using the Python SDK, there is no easy way to do it. Logic is buried in the `ACRExchangeClient` class which is not supposed to be used directly.
**Describe the solution you'd like**
A method directly available on the `ContainerRegistryClient` class to get the ACR token that can then be used for `docker login` command.
**Describe alternatives you've considered**
I considered hack around the `ACRExchangeClient` and `ContainerRegistryChallengePolicy` classes but that just doesn't feel right.
**Additional context**
Similar feature request has been made on the [JS SDK](https://github.com/Azure/azure-sdk-for-js/issues/27635)
Guida per i contributori
Apri la guida per i contributori
Valutazione
Questa issue non è ancora stata valutata.