-
Notifications
You must be signed in to change notification settings - Fork 297
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
Clarification on use of user-assigned managed identity and github-hosted runners #489
Comments
Hi @matsest , I think you are confusing the two methods: If you want to use user-assigned managed identity on github-hosted runners, you can only use OIDC or SP+Secret. The statement in login-with-user-assigned-managed-identity is correct. You can simply click the guides links to see how it works. (Just check how to configure it on Azure and GitHub.) I think your questions will be answered. FYI, we also maintain the official guidance on MS Learn. This page official guidance on MS Learn corresponds to login-with-openid-connect-oidc. And the page Use the Azure Login action with a managed identity corresponds to login-with-system-assigned-managed-identity and login-with-user-assigned-managed-identity. |
Thanks for reply @YanaXu! I see that the method described under "Login With OpenID Connect (OIDC)" describes that it is possible to use user-assigned managed identity, which is what I am also stating in this question and what I have tested to work successfully. I guess this is more about how the README content is structured and how it matches to the documentation provided on MS Learn. Some comments:
For users who want to use 1) User-Assigned Managed Identity and 2) GitHub-hosted Runners it should be clear from the README what example in the README is relevant for them. To me the current "Login With User-Assigned Managed Identity" seems at first glance to be the relevant section, but is not the correct one (Login With OpenID Connect (OIDC) is). If the part about "Azure VM" had been more clearly stated it would be a more clear distinction. |
Thanks, @matsest, I was confused about the wording of the headings as well. I also agree that adding "on an Azure VM" or "self-hosted Azure VM" would be helpful :) |
The content of this action's README is conflicting with official guidance on MS Learn regarding the use of user-assigned managed identities (UAMI). The documentation listed above gives example of workflow to use with github-hosted runners and UAMI.
The README in the repo, however, states:
and gives the example
where we can see
runs-on: self-hosted
andauth-type: IDENTITY
.From my own testing and long-time usage I can still use UAMI and github-hosted runners with this action, when not setting
auth-type
toIDENTITY
:When using the same UAMI and setting
auth-type: IDENTITY
I get errors (see run, workflow file):Error: Failed to connect to MSI, check your managed service identity id.
This is also tested by explicitly setting
auth-type: SERVICE_PRINCIPAL
(see run, workflow file) which again works fine.Based on my testing and experience with managed identities I would assume that the restriction on using
auth-type: IDENTITY
and self-hosted runners only really applies to system-assigned managed identities?The text was updated successfully, but these errors were encountered: