Skip to content

Commit

Permalink
add write permission for artifact deletion
Browse files Browse the repository at this point in the history
  • Loading branch information
AlvinSchiller committed Feb 4, 2024
1 parent c2d60cb commit a91772b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/test_docker_debian.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ jobs:

# Build container and run tests
run:
permissions:
actions: write
name: ${{ matrix.debian_codename }}
strategy:
fail-fast: false
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/test_docker_debian_codename_sub.yml
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,8 @@ jobs:
# cleanup after test execution
cleanup:
permissions:
actions: write
# run only if tests didn't fail: keep the artifact to make job reruns possible
if: ${{ !failure() }}
needs: [build, test]
Expand All @@ -180,3 +182,5 @@ jobs:
uses: geekyeggo/delete-artifact@v4
with:
name: ${{ needs.build.outputs.image_file_name }}
# on PRs no write permissions are granted, so this fails in this cases
failOnError: false

0 comments on commit a91772b

Please sign in to comment.