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

[Task] Consider using GITHUB_TOKEN in submodule workflow #1108

Open
ebaron opened this issue Sep 12, 2023 · 3 comments
Open

[Task] Consider using GITHUB_TOKEN in submodule workflow #1108

ebaron opened this issue Sep 12, 2023 · 3 comments
Labels
ci help wanted Extra attention is needed

Comments

@ebaron
Copy link
Member

ebaron commented Sep 12, 2023

If we can use GITHUB_TOKEN with write access to update Cryostat's submodule we should do that instead of using a Personal Access Token. This would also be useful for the similar workflow in the Helm Chart.

token: "${{ secrets.SUBMODULE_TOKEN }}"

@ebaron ebaron added help wanted Extra attention is needed ci labels Sep 12, 2023
@ebaron ebaron moved this to Stretch Goals in 2.4.0 release Sep 12, 2023
@ebaron
Copy link
Member Author

ebaron commented Sep 12, 2023

This may not be possible since in this case we're writing to a different repo within the org, but it's worth exploring to see if it's doable.

@tthvo
Copy link
Member

tthvo commented Sep 12, 2023

I guess a solution can be:

  • Add a workflow on target repository that will automatically merge when PR is labeled with auto-merge (maybe also need automatic approvals).
  • Update this workflow to open the PR (instead of direct push) to update submodule with label auto-merge.

This way, merge action will use the target repository token.

@mwangggg mwangggg self-assigned this Dec 18, 2023
@mwangggg
Copy link
Member

I don't think this is possible right now without a PAT due to the limitations of the GITHUB_TOKEN permissions. Since we want to keep it automated, I'll just leave it as is :)

@mwangggg mwangggg removed their assignment Dec 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci help wanted Extra attention is needed
Projects
No open projects
Status: Stretch Goals
Development

No branches or pull requests

3 participants