actions - add notification
This commit is contained in:
		| @@ -22,5 +22,22 @@ jobs: | |||||||
| #          files: |- | #          files: |- | ||||||
| #            _site/** | #            _site/** | ||||||
| #          token: "${{ secrets.RELEASE_TOKEN }}" | #          token: "${{ secrets.RELEASE_TOKEN }}" | ||||||
|  |   notification: | ||||||
|  |     runs-on: ubuntu-latest | ||||||
|  |     needs: build | ||||||
|  |     steps: | ||||||
|  |       - name: create payload var | ||||||
|  |         runs: | | ||||||
|  |           PAYLOAD=$(cat << EOF | ||||||
|  |           payload={ | ||||||
|  |             \"username\": \"gitea-bot\", | ||||||
|  |             \"icon_url\": \"https://icinga.com/wp-content/uploads/2017/08/icon-core.png\", | ||||||
|  |             \"text\": \"mkdocs build has just finished !\" | ||||||
|  |           } | ||||||
|  |           EOF | ||||||
|  |           ) | ||||||
|  |         id: my_payload | ||||||
|  |       - name: curl webhook | ||||||
|  |         runs: | | ||||||
|  |           curl --connect-timeout 30 --max-time 60 -s -S -X POST --data-urlencode "${{ env.PAYLOAD }}" "${{ secrets.WEBHOOK_URL }}" | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user