-
Couldn't load subscription status.
- Fork 325
Split publish and deploy workflows #4057
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
base: main
Are you sure you want to change the base?
Conversation
|
cd513d3 to
fd571a7
Compare
| name: Clean up ephemeral items | ||
| runs-on: ubuntu-latest | ||
| needs: | ||
| - calculate-changes | ||
| - publish-adapter-images | ||
| if: always() && needs.calculate-changes.outputs.adapter-list != '[]' | ||
| steps: | ||
| - name: Check out code | ||
| uses: actions/checkout@v4 | ||
| with: | ||
| ref: ${{ needs.calculate-changes.outputs.tmp-branch }} | ||
| - name: Delete ephemeral branch | ||
| run: | | ||
| git push origin --delete ${{ needs.calculate-changes.outputs.tmp-branch }} |
Check warning
Code scanning / CodeQL
Workflow does not contain permissions Medium
Show autofix suggestion
Hide autofix suggestion
Copilot Autofix
AI about 1 month ago
To fix the problem, add an explicit permissions block under the cleanup job in .github/workflows/publish.yml. This block should specify the minimal required permissions for the steps it performs. Since the job deletes a branch—an operation that requires write access to repository contents—the permissions should be set to contents: write. This change should be added directly under the runs-on and needs listings in the cleanup job (after line 121 and before line 125 for style consistency). No additional imports or dependencies are required.
-
Copy modified lines R122-R123
| @@ -119,6 +119,8 @@ | ||
| cleanup: | ||
| name: Clean up ephemeral items | ||
| runs-on: ubuntu-latest | ||
| permissions: | ||
| contents: write | ||
| needs: | ||
| - calculate-changes | ||
| - publish-adapter-images |
b5cfff0 to
0315644
Compare
56d47e0 to
854e84d
Compare
854e84d to
4a9ad8a
Compare
Closes #ISSUE_NUMBER_GOES_HERE
Description
......
Changes
Steps to Test
Quality Assurance
infra-k8sconfiguration file.adapter-secretsconfiguration file or update the soak testing blacklist.test-payload.jsonfile with relevant requests.feature/x,chore/x,release/x,hotfix/x,fix/x) or is created from Jira.