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

[workflows] Use a custom token for creating backport PRs #79501

Merged
merged 1 commit into from
Jan 26, 2024

Conversation

tstellar
Copy link
Collaborator

The CI tests don't get triggered if a PR is created by the builtin github token, so we need to use a custom token when creating a PR.

The CI tests don't get triggered if a PR is created by the
builtin github token, so we need to use a custom token when creating
a PR.
@llvmbot
Copy link
Collaborator

llvmbot commented Jan 25, 2024

@llvm/pr-subscribers-github-workflow

Author: Tom Stellard (tstellar)

Changes

The CI tests don't get triggered if a PR is created by the builtin github token, so we need to use a custom token when creating a PR.


Full diff: https://github.com/llvm/llvm-project/pull/79501.diff

1 Files Affected:

  • (modified) .github/workflows/issue-release-workflow.yml (+1-1)
diff --git a/.github/workflows/issue-release-workflow.yml b/.github/workflows/issue-release-workflow.yml
index 112ece40bac9c1a..33a1e89a729f6b1 100644
--- a/.github/workflows/issue-release-workflow.yml
+++ b/.github/workflows/issue-release-workflow.yml
@@ -61,7 +61,7 @@ jobs:
           printf "%s" "$COMMENT_BODY" |
           ./llvm/utils/git/github-automation.py \
           --repo "$GITHUB_REPOSITORY" \
-          --token ${{ github.token }} \
+          --token "${{ secrets.RELEASE_WORKFLOW_PR_CREATE }}" \
           release-workflow \
           --branch-repo-token ${{ secrets.RELEASE_WORKFLOW_PUSH_SECRET }} \
           --issue-number ${{ github.event.issue.number }} \

@@ -61,7 +61,7 @@ jobs:
printf "%s" "$COMMENT_BODY" |
./llvm/utils/git/github-automation.py \
--repo "$GITHUB_REPOSITORY" \
--token ${{ github.token }} \
--token "${{ secrets.RELEASE_WORKFLOW_PR_CREATE }}" \
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just to double check, does this token also have permission to create issue comments? It will be used for that as well.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just added issue permissions to the token.

@tstellar tstellar merged commit d2c8167 into llvm:main Jan 26, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants