Skip to content

Commit

Permalink
Cherry picking CI fixes for v0.34.1 fix
Browse files Browse the repository at this point in the history
Original commits:

[ci] making sure the release has proper rights
[ci] making sure release publication doesn't hurt deploy
  • Loading branch information
DavyLandman committed Oct 27, 2023
1 parent d48d236 commit b7a3582
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ jobs:
builds:
if: ${{ !(github.ref == 'refs/heads/main' && contains(github.event.head_commit.message, '[maven-release-plugin]')) }}
needs: [test-linux]
permissions:
contents: write
runs-on: buildjet-4vcpu-ubuntu-2204
steps:
- uses: browser-actions/setup-chrome@latest
Expand Down Expand Up @@ -88,15 +90,6 @@ jobs:
tests (buildjet-4vcpu-ubuntu-2204-arm)
ttl: 15

- name: Prepare Draft Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
draft: true
files: ${{ steps.build-artifact.outputs.artifact-root-dir}}/**/*
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Deploy
if: startsWith(github.ref, 'refs/tags/v')
uses: usethesource/releases-maven-action@v1
Expand All @@ -109,6 +102,15 @@ jobs:
ssh-username: ${{ secrets.RELEASE_SSH_USERNAME }}
ssh-private-key: ${{ secrets.RELEASE_SSH_PRIVATE_KEY }}

- name: Prepare Draft Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
draft: true
files: ${{ steps.build-artifact.outputs.artifact-root-dir}}/**/*
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}


tests:
if: ${{ !(github.ref == 'refs/heads/main' && contains(github.event.head_commit.message, '[maven-release-plugin]')) }}
Expand Down

0 comments on commit b7a3582

Please sign in to comment.