I can login to Azure ACR using the service principal id and key
- uses: azure/docker-login@v1
with:
login-server: contoso.azurecr.io
username: ${{ secrets.REGISTRY_USERNAME }}
password: ${{ secrets.REGISTRY_PASSWORD }}
Where you can set the REGISTRY_USERNAME as your service principal id and REGISTRY_PASSWORD as your service principal key.
Great!
but, then I need to pass two additional secrets to my github actions. And I want to reduce it down to just having to provide my entire credentials json blog, and the login action could extract the id and key from it.
so, basically, I would like the action to look something like this:
By supporting this, I would just have to pass one secret (my SP credentials) to github action secrets and then I can both push to my registry and for example deploy new Azure Container Instances.
As described here: https://github.com/Azure/docker-login/issues/23
I can login to Azure ACR using the service principal id and key
Great!
but, then I need to pass two additional secrets to my github actions. And I want to reduce it down to just having to provide my entire credentials json blog, and the login action could extract the id and key from it.
so, basically, I would like the action to look something like this:
By supporting this, I would just have to pass one secret (my SP credentials) to github action secrets and then I can both push to my registry and for example deploy new Azure Container Instances.