Skip to content
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

Allow login using service credentials dirctly #54

Open
JoeMarkov opened this issue Mar 6, 2023 · 1 comment
Open

Allow login using service credentials dirctly #54

JoeMarkov opened this issue Mar 6, 2023 · 1 comment
Labels
need-to-triage Requires investigation

Comments

@JoeMarkov
Copy link

As described here:
#23

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:

- uses: azure/docker-login@v1
  with:
    login-server: contoso.azurecr.io
    credentials: ${{ secrets.Azure_ServicePrincipal_Credentials }}
   

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.

@JoeMarkov JoeMarkov added the need-to-triage Requires investigation label Mar 6, 2023
@lgmorand
Copy link
Collaborator

I do agree. it could a nice option. feel free to do a PR to bring it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
need-to-triage Requires investigation
Projects
None yet
Development

No branches or pull requests

2 participants