Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
CI wrench: update notification messages; do notify on error only
authorMartin Quinson <martin.quinson@ens-rennes.fr>
Sun, 12 Sep 2021 19:46:54 +0000 (21:46 +0200)
committerMartin Quinson <martin.quinson@ens-rennes.fr>
Sun, 12 Sep 2021 19:46:54 +0000 (21:46 +0200)
.github/workflows/ci-wrench.yml

index 5baaaef..c8358ab 100644 (file)
@@ -36,12 +36,13 @@ jobs:
       - name: Create the failure Message
         if: ${{ failure() }}
         run: |
-          echo "{\"attachments\": [{\"color\": \"#FF0000\", \"text\":\"Failure when building docker images ! See ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} \"}]}" > mattermost.json
+          echo "{\"attachments\": [{\"color\": \"#FF0000\", \"text\":\"Wrench's git failed to build on simgrid/unstable docker image! See ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} \"}]}" > mattermost.json
       - name: Create the success Message
         if: ${{ success() }}
         run: |
-          echo "{\"attachments\": [{\"color\": \"#00FF00\", \"text\":\"Docker images built and pushed successfully ! ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} \"}]}" > mattermost.json
+          echo "{\"attachments\": [{\"color\": \"#00FF00\", \"text\":\"Wrench's git successfully built on simgrid/unstable docker image. ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} \"}]}" > mattermost.json
       - uses: mattermost/action-mattermost-notify@master
+        if: ${{ failure() }}
         env:
           MATTERMOST_WEBHOOK_URL: ${{ secrets.MATTERMOST_WEBHOOK_URL }}
           MATTERMOST_CHANNEL: ${{ secrets.MATTERMOST_CHANNEL}}