ASFHyP3 / hyp3-cookiecutter

Cookiecutter to quickly generate a new HyP3 Plugin
BSD 3-Clause "New" or "Revised" License
4 stars 4 forks source link

Need better documentation on how to set permissions for `GITHUB_PAK` #23

Closed forrestfwilliams closed 5 months ago

forrestfwilliams commented 1 year ago

In order to get the CI/CD working correctly, the user of the cookiecutter will need to create a Personal Access Token with a certain set of permissions. We should document:

  1. Which type of access token they should create (Classic or Fine-Grained) - I believe the answer is Classic?
  2. What is the minimal set of boxes in the screenshot below that need to be checked in order for the actions to work?
Screen Shot 2023-03-20 at 9 25 51 AM
forrestfwilliams commented 1 year ago

@jhkennedy and @jtherrmann I'd enjoy hearing your thoughts on this one.

jtherrmann commented 1 year ago

Maybe try checking what perms are available to tools-bot: https://github.com/orgs/ASFHyP3/people/tools-bot (if possible)

jtherrmann commented 1 year ago

tools-bot has a classic token with these perms:

tools-bot-token-perms

forrestfwilliams commented 1 year ago

Here's the new screenshot (in two pieces)

Screen Shot 2023-03-24 at 8 08 00 AM
forrestfwilliams commented 1 year ago
Screen Shot 2023-03-24 at 8 09 09 AM
jacquelynsmale commented 5 months ago

@forrestfwilliams and I ran into this issue (or a similar issue) running hyp3-cookiecutter to create hyp3-back-projection. We missed updating $GITHUB-PAK, and had to go back to fix it. Could this be included as a variable in the cookiecutter.json file, rather than hardcoding it to be $GITHUB-PAK?

jhkennedy commented 5 months ago

@jtherrmann @forrestfwilliams for our own repos, you can just change GITHUB_PAK to TOOLS_BOT_PAK. GITHUB_PAK was intended to be the generic version of that for external users.

But, yes, documenting what's needed here is a good idea.

jhkennedy commented 5 months ago

Actually, it's already in the README with a screenshot: https://github.com/ASFHyP3/hyp3-cookiecutter?tab=readme-ov-file#6-create-a-personal-access-key-for-github-actions

jhkennedy commented 5 months ago

Looks like @forrestfwilliams did in https://github.com/ASFHyP3/hyp3-cookiecutter/pull/31, but we never closed the issue

forrestfwilliams commented 5 months ago

Looks like I should have read my own documentation 😭!