Skip to content

Commit ccb1de3

Browse files
author
lgdd
committed
🔧 Add rollback release step in case of failure
1 parent 2982d8d commit ccb1de3

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

.github/workflows/release.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ jobs:
2323
draft: false
2424
prerelease: false
2525

26-
build_upload_release_assets:
27-
name: Build & Upload Release Assets
26+
publish_release:
27+
name: Publish Release
2828
needs: create_release
2929
runs-on: ubuntu-latest
3030
strategy:
@@ -62,3 +62,9 @@ jobs:
6262
asset_path: ./build/libs/com.github.lgdd.liferay.health-${{ env.APP_VERSION }}.jar
6363
asset_name: com.github.lgdd.liferay.health-${{ env.APP_VERSION }}-jdk${{ matrix.java }}.jar
6464
asset_content_type: application/octet-stream
65+
- name: Rollback Release
66+
if: failure() && needs.create_release.outputs.id != ''
67+
uses: author/action-rollback@stable
68+
with:
69+
id: ${{ needs.create_release.id }}
70+
tag: ${{ github.ref }}

0 commit comments

Comments
 (0)