diff --git a/.github/workflows/PR-Demo-Comment.yml b/.github/workflows/PR-Demo-Comment-with-react.yml similarity index 83% rename from .github/workflows/PR-Demo-Comment.yml rename to .github/workflows/PR-Demo-Comment-with-react.yml index 75244dc91..47efbf82c 100644 --- a/.github/workflows/PR-Demo-Comment.yml +++ b/.github/workflows/PR-Demo-Comment-with-react.yml @@ -34,6 +34,7 @@ jobs: pr_number: ${{ steps.get-pr.outputs.pr_number }} pr_repository: ${{ steps.get-pr-info.outputs.repository }} pr_ref: ${{ steps.get-pr-info.outputs.ref }} + comment_id: ${{ github.event.comment.id }} steps: - name: Harden Runner @@ -73,6 +74,20 @@ jobs: core.setOutput('repository', repository); core.setOutput('ref', pr.head.ref); + - name: Add 'in_progress' reaction to comment + uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1 + with: + script: | + const { owner, repo } = context.repo; + const commentId = context.payload.comment.id; + + await github.rest.reactions.createForIssueComment({ + owner, + repo, + comment_id: commentId, + content: 'eyes' + }); + deploy-pr: needs: check-comment runs-on: ubuntu-latest @@ -137,6 +152,7 @@ jobs: sudo chmod 600 ../private.key - name: Deploy to VPS + id: deploy run: | # First create the docker-compose content locally cat > docker-compose.yml << 'EOF' @@ -180,6 +196,36 @@ jobs: docker-compose up -d ENDSSH + - name: Add success reaction to comment + if: success() + uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1 + with: + script: | + const { owner, repo } = context.repo; + const commentId = ${{ needs.check-comment.outputs.comment_id }}; + + await github.rest.reactions.createForIssueComment({ + owner, + repo, + comment_id: commentId, + content: 'rocket' + }); + + - name: Add failure reaction to comment + if: failure() + uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1 + with: + script: | + const { owner, repo } = context.repo; + const commentId = ${{ needs.check-comment.outputs.comment_id }}; + + await github.rest.reactions.createForIssueComment({ + owner, + repo, + comment_id: commentId, + content: '-1' + }); + - name: Post deployment URL to PR if: success() uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1 diff --git a/.github/workflows/multiOSReleases.yml b/.github/workflows/multiOSReleases.yml index f2c8867de..02f064d60 100644 --- a/.github/workflows/multiOSReleases.yml +++ b/.github/workflows/multiOSReleases.yml @@ -264,6 +264,7 @@ jobs: name: ${{ matrix.platform }}signed path: | ./Stirling-PDF-${{ matrix.platform }}installer.* + ./Stirling-PDF-${{ matrix.platform }}-x86_64-installer.* !cosign.* create-release: