|
3 | 3 | workflow_dispatch:
|
4 | 4 | schedule: # UTC at 0300
|
5 | 5 | - cron: "0 3 * * *"
|
| 6 | + # Trigger workflow when file is modified |
| 7 | + push: |
| 8 | + paths: |
| 9 | + - '.github/workflows/nightly_docker_test.yml' |
6 | 10 |
|
7 | 11 | env:
|
8 | 12 | MAIN_PYTHON_VERSION: '3.12'
|
@@ -104,9 +108,27 @@ jobs:
|
104 | 108 | if: failure()
|
105 | 109 | with:
|
106 | 110 | webhook_url: ${{ secrets.MSTEAMS_WEBHOOK }}
|
107 |
| - needs: ${{ toJson(needs) }} |
108 |
| - job: ${{ toJson(job) }} |
109 |
| - steps: ${{ toJson(steps) }} |
| 111 | + # Message to send to Teams as a webhook notification in JSON Payload format |
| 112 | + raw: >- |
| 113 | + { |
| 114 | + "@type": "MessageCard", |
| 115 | + "@context": "http://schema.org/extensions", |
| 116 | + "summary": "Nightly Tests for Windows failing", |
| 117 | + "themeColor": "f44336", |
| 118 | + "title": "PyAnsys Geometry Nightly Tests - Windows failing", |
| 119 | + "sections": [ |
| 120 | + { |
| 121 | + "activityTitle": "Windows nightly tests are failing", |
| 122 | + "activitySubtitle": "Check the run for more details: https://github.com/ansys/pyansys-geometry/actions/runs/${{ github.run_id }}", |
| 123 | + "facts": [ |
| 124 | + { |
| 125 | + "name": "Status", |
| 126 | + "value": "Failed" |
| 127 | + } |
| 128 | + ] |
| 129 | + } |
| 130 | + ] |
| 131 | + } |
110 | 132 |
|
111 | 133 | # =================================================================================================
|
112 | 134 | # ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ RUNNING ON SELF-HOSTED RUNNER ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
@@ -150,6 +172,24 @@ jobs:
|
150 | 172 | if: failure()
|
151 | 173 | with:
|
152 | 174 | webhook_url: ${{ secrets.MSTEAMS_WEBHOOK }}
|
153 |
| - needs: ${{ toJson(needs) }} |
154 |
| - job: ${{ toJson(job) }} |
155 |
| - steps: ${{ toJson(steps) }} |
| 175 | + # Message to send to Teams as a webhook notification in JSON Payload format |
| 176 | + raw: >- |
| 177 | + { |
| 178 | + "@type": "MessageCard", |
| 179 | + "@context": "http://schema.org/extensions", |
| 180 | + "summary": "Nightly Tests for Linux failing", |
| 181 | + "themeColor": "f44336", |
| 182 | + "title": "PyAnsys Geometry Nightly Tests - Linux failing", |
| 183 | + "sections": [ |
| 184 | + { |
| 185 | + "activityTitle": "Linux nightly tests are failing", |
| 186 | + "activitySubtitle": "Check the run for more details: https://github.com/ansys/pyansys-geometry/actions/runs/${{ github.run_id }}", |
| 187 | + "facts": [ |
| 188 | + { |
| 189 | + "name": "Status", |
| 190 | + "value": "Failed" |
| 191 | + } |
| 192 | + ] |
| 193 | + } |
| 194 | + ] |
| 195 | + } |
0 commit comments