Conversation
Signed-off-by: Carlos Rodríguez Hernández <carlos.rodriguez-hernandez@broadcom.com> ai-assisted=no
| # pull_request: fork PRs do not receive base-repo secrets; BOT_TOKEN push only runs for same-repo PRs. | ||
| on: # rebuild any PRs and main branch changes | ||
| pull_request_target: | ||
| pull_request: |
There was a problem hiding this comment.
We tried this change in the past and you have the explanation why we reverted the change in the comment above. Most of our PRs come from forked repositories and we need a PAT token to commit changes (changelog and readme) in forked repositories.
| contents: read | ||
| if: | | ||
| needs.get-chart.outputs.result == 'ok' && | ||
| github.event.pull_request.head.repo.full_name == github.repository && |
There was a problem hiding this comment.
I assume you are adding this condition to avoid running this piece of code in private repositories. To do that we usually add this condition:
| github.event.pull_request.head.repo.full_name == github.repository && | |
| github.repository_owner == 'bitnami' && |
| - name: Checkout bitnami/charts (PR merge ref) | ||
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | ||
| with: | ||
| ref: ${{github.event.pull_request.head.ref}} |
| # pull_request + default checkout uses the merge ref; avoids pull_request_target + PR head checkout. | ||
| on: | ||
| pull_request_target: | ||
| pull_request: |
There was a problem hiding this comment.
We tried this change in the past. apache/skywalking-eyes/header action requires permissions to change the PR and add comments with the failures. On pull_request events comming from forked repositories, the github_action token does not have enough permissions to change a PR in the bitnami/charts repository.
| steps: | ||
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd | ||
| name: Checkout Repository | ||
| with: |
There was a problem hiding this comment.
Don't change this. We can not use pull_request
No description provided.