From ee03bdd4794855396a8267fc97b2b13358240936 Mon Sep 17 00:00:00 2001 From: Oleg S <97077423+RobotSail@users.noreply.github.com> Date: Wed, 18 Dec 2024 08:45:01 -0500 Subject: [PATCH] feat: add discord e2e status reporting Since we have recently added Discord as another chat platform, we should also report the status of E2E jobs there in addition to Slack. This commit introduces this capability by mirroring a PR that was made in instructlab/eval: https://github.com/instructlab/eval/pull/200 Signed-off-by: Oleg S <97077423+RobotSail@users.noreply.github.com> --- .github/workflows/e2e-nvidia-l40s-x4.yml | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/.github/workflows/e2e-nvidia-l40s-x4.yml b/.github/workflows/e2e-nvidia-l40s-x4.yml index 21b1560c..fdd2b480 100644 --- a/.github/workflows/e2e-nvidia-l40s-x4.yml +++ b/.github/workflows/e2e-nvidia-l40s-x4.yml @@ -257,6 +257,30 @@ jobs: env: SLACK_BOT_TOKEN: ${{ secrets.SON_OF_JEEVES_TOKEN }} + - name: Send Discord notification for failure + if: failure() && steps.check_pr.outputs.is_pr == 'false' + uses: sarisia/actions-status-discord@65843b6a7d18626c252a055e247ccad1f41b4004 # v1.15.1 + with: + webhook: ${{ secrets.SON_OF_JEEVES_DISCORD_WEBHOOK }} + status: ${{ job.status }} + title: "e2e-nvidia-l40s-x4" + description: | + Job in **${{ github.repository }}** running on branch `${{ steps.check_pr.outputs.pr_or_branch }}` completed **with failures** ❌ + Click [here](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}) to view details. + color: 0xCB2431 # Red color for failure + + - name: Send Discord notification for success + if: success() && steps.check_pr.outputs.is_pr == 'false' + uses: sarisia/actions-status-discord@65843b6a7d18626c252a055e247ccad1f41b4004 # v1.15.1 + with: + webhook: ${{ secrets.SON_OF_JEEVES_DISCORD_WEBHOOK }} + status: ${{ job.status }} + title: "e2e-nvidia-l40s-x4" + description: | + Job in **${{ github.repository }}** running on branch `${{ steps.check_pr.outputs.pr_or_branch }}` completed **successfully** ✅ + Click [here](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}) to view details. + color: 0x28A745 # Green color for success + stop-large-ec2-runner: needs: - start-large-ec2-runner