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

Add GH App Auth support #29

Conversation

MatteoManzoni
Copy link
Contributor

This PR introduces the support for GH App Auth in the action.
With the support to GH App Auth this action should be able to require less privileges than org:admin which, in many cases, is deemed too broad to be used.

The input requirements of the modified action to use GH App Auth are:

  • gh_app_secret_key: the RSA secret key generated during the App creation process used to sign App JWT tokens
  • gh_app_ID: GH App ID
  • gh_app_installation_ID: Installation ID of the App on your org

@leonsteinhaeuser
Copy link
Owner

@MatteoManzoni thank you very much for providing this solution. I would like to ask you to write a few sentences in the README.md so that others can understand what they need to do to use this feature.

@MatteoManzoni
Copy link
Contributor Author

Sure @leonsteinhaeuser, I've totally forgot. I'll add documentation for the new variables and a new paragraph with GH App specific instructions, soon.

@leonsteinhaeuser leonsteinhaeuser added new feature size/XS Denotes a PR that changes 0-99 lines, ignoring generated files. labels Jan 28, 2022
@MatteoManzoni
Copy link
Contributor Author

Hey @leonsteinhaeuser, I've update the README, let me know if you have any feedback

@leonsteinhaeuser leonsteinhaeuser changed the base branch from main to release-v1.2.0 February 5, 2022 16:23
@leonsteinhaeuser leonsteinhaeuser added size/S Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-99 lines, ignoring generated files. labels Feb 5, 2022
@leonsteinhaeuser leonsteinhaeuser merged commit 065bf0a into leonsteinhaeuser:release-v1.2.0 Feb 5, 2022
@leonsteinhaeuser
Copy link
Owner

leonsteinhaeuser commented Feb 5, 2022

@MatteoManzoni first of all great work.

When I added this function to the release-v1.2.0 branch and created a pre-release version from it, I found in my testing that the action.yml file pointed to the wrong script.

 /home/runner/work/_temp/f4f8965b-ec35-40a2-ae04-ecd5ab7ed8e3.sh: line 27: /home/runner/work/_actions/leonsteinhaeuser/project-beta-automations/v1.2.0-alpha.1/ghapp_credential_helper.sh: No such file or directory
could not prompt: EOF
25l? How would you like to authenticate GitHub CLI?  [Use arrows to move, type to filter]
> Login with a web browser
  Paste an authentication token
25h

Since it was just a typo, I fixed it so we can release this feature soon.

@MatteoManzoni
Copy link
Contributor Author

@MatteoManzoni first of all great work.

When I added this function to the release-v1.2.0 branch and created a pre-release version from it, I found in my testing that the action.yml file pointed to the wrong script.

 /home/runner/work/_temp/f4f8965b-ec35-40a2-ae04-ecd5ab7ed8e3.sh: line 27: /home/runner/work/_actions/leonsteinhaeuser/project-beta-automations/v1.2.0-alpha.1/ghapp_credential_helper.sh: No such file or directory
could not prompt: EOF
25l? How would you like to authenticate GitHub CLI?  [Use arrows to move, type to filter]
> Login with a web browser
  Paste an authentication token
25h

Since it was just a typo, I fixed it so we can release this feature soon.

@leonsteinhaeuser thank you so much, that was definitely a typo

@leonsteinhaeuser
Copy link
Owner

@MatteoManzoni this feature is now available with version v1.2.0

@MatteoManzoni
Copy link
Contributor Author

Thank you so much @leonsteinhaeuser

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new feature size/S Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

None yet

2 participants