From 9e40464500a58f6170e1b7ba95daaae698a28a1f Mon Sep 17 00:00:00 2001 From: Daniel Pawlik Date: Fri, 7 Nov 2025 11:08:31 +0100 Subject: [PATCH 1/2] Change Github Action permissions Currently the commit-message-validator.yml Github Action raise an issue when the commit message is improper: Resource not accessible by integration Let's try if this would help. Signed-off-by: Daniel Pawlik --- .../workflows/commit-message-validator.yml | 31 ++++++++++++++++--- 1 file changed, 26 insertions(+), 5 deletions(-) diff --git a/.github/workflows/commit-message-validator.yml b/.github/workflows/commit-message-validator.yml index 075a47e58..098d043fe 100644 --- a/.github/workflows/commit-message-validator.yml +++ b/.github/workflows/commit-message-validator.yml @@ -1,26 +1,46 @@ name: Check if commit message body is not too short on: + pull_request_target: + types: [opened, synchronize, edited, reopened] pull_request: types: [opened, synchronize, edited, reopened] +permissions: {} + jobs: verify-body-length: runs-on: ubuntu-latest # set as non-voting for now. continue-on-error: true - permissions: - contents: write - pull-requests: write - repository-projects: write - steps: - name: Checkout repository uses: actions/checkout@v4 with: fetch-depth: 0 + - name: Generate GitHub App Token + id: generate_token + uses: actions/create-github-app-token@v2 + with: + app-id: ${{ secrets.COMMENTER_APP_ID }} + private-key: ${{ secrets.COMMENTER_APP_PRIVATE_KEY }} + owner: ${{ github.repository_owner }} + repositories: ci-framework + + - name: Post comment + uses: actions/github-script@v7 + with: + github-token: ${{ steps.generate_token.outputs.token }} + script: | + github.rest.issues.createComment({ + owner: context.repo.owner, + repo: context.repo.repo, + issue_number: context.issue.number, + body: 'my comment' + }) + - name: Dump commit message to file run: | git fetch origin ${{ github.event.pull_request.head.sha }} @@ -42,3 +62,4 @@ jobs: issue-number: ${{ github.event.pull_request.number }} body-path: ./result.log reactions: confused + token: ${{ steps.generate_token.outputs.token }} From 26ddbf21433735c88a494cc562020ecd82570ed8 Mon Sep 17 00:00:00 2001 From: Michael Burke Date: Tue, 11 Nov 2025 11:02:15 -0500 Subject: [PATCH 2/2] test commit --- roles/reproducer/defaults/main.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/roles/reproducer/defaults/main.yml b/roles/reproducer/defaults/main.yml index ca312765d..e41e339e4 100644 --- a/roles/reproducer/defaults/main.yml +++ b/roles/reproducer/defaults/main.yml @@ -15,8 +15,8 @@ # under the License. -# All variables intended for modification should be placed in this file. -# All variables within this role should have a prefix of "cifmw_reproducer" +# All variables intended for modification should be placed in this file +# All variables within this role should have a prefix of "cifmw_reproducer". cifmw_reproducer_controller_user: "{{ hostvars['controller-0']['ansible_ssh_user'] | default('zuul') }}" cifmw_reproducer_controller_user_dir: "/home/{{ cifmw_reproducer_controller_user }}" cifmw_reproducer_controller_basedir: "{{ cifmw_reproducer_controller_user_dir }}/ci-framework-data"