noti build

This commit is contained in:
kittapath 2025-02-24 10:08:05 +07:00
parent c4e857e491
commit 5d416b0315

View file

@ -67,40 +67,40 @@ jobs:
docker compose pull docker compose pull
docker compose up -d docker compose up -d
echo "${{ steps.gen_ver.outputs.image_ver }}"> success echo "${{ steps.gen_ver.outputs.image_ver }}"> success
# - name: Notify Discord Success - name: Notify Discord Success
# if: success() if: success()
# run: | run: |
# curl -H "Content-Type: application/json" \ curl -H "Content-Type: application/json" \
# -X POST \ -X POST \
# -d '{ -d '{
# "embeds": [{ "embeds": [{
# "title": "✅ Deployment Success!", "title": "✅ Deployment Success!",
# "description": "**Details:**\n- Image: `${{env.IMAGE_NAME}}`\n- Version: `${{ steps.gen_ver.outputs.image_ver }}`\n- Deployed by: `${{github.actor}}`", "description": "**Details:**\n- Image: `${{env.IMAGE_NAME}}`\n- Version: `${{ steps.gen_ver.outputs.image_ver }}`\n- Deployed by: `${{github.actor}}`",
# "color": 3066993, "color": 3066993,
# "footer": { "footer": {
# "text": "Release Notification", "text": "Release Notification",
# "icon_url": "https://example.com/success-icon.png" "icon_url": "https://example.com/success-icon.png"
# }, },
# "timestamp": "'$(date -u +%Y-%m-%dT%H:%M:%SZ)'" "timestamp": "'$(date -u +%Y-%m-%dT%H:%M:%SZ)'"
# }] }]
# }' \ }' \
# ${{ secrets.DISCORD_WEBHOOK }} ${{ secrets.DISCORD_WEBHOOK }}
# - name: Notify Discord Failure - name: Notify Discord Failure
# if: failure() if: failure()
# run: | run: |
# curl -H "Content-Type: application/json" \ curl -H "Content-Type: application/json" \
# -X POST \ -X POST \
# -d '{ -d '{
# "embeds": [{ "embeds": [{
# "title": "❌ Deployment Failed!", "title": "❌ Deployment Failed!",
# "description": "**Details:**\n- Image: `${{env.IMAGE_NAME}}`\n- Version: `${{ steps.gen_ver.outputs.image_ver }}`\n- Attempted by: `${{github.actor}}`", "description": "**Details:**\n- Image: `${{env.IMAGE_NAME}}`\n- Version: `${{ steps.gen_ver.outputs.image_ver }}`\n- Attempted by: `${{github.actor}}`",
# "color": 15158332, "color": 15158332,
# "footer": { "footer": {
# "text": "Release Notification", "text": "Release Notification",
# "icon_url": "https://example.com/failure-icon.png" "icon_url": "https://example.com/failure-icon.png"
# }, },
# "timestamp": "'$(date -u +%Y-%m-%dT%H:%M:%SZ)'" "timestamp": "'$(date -u +%Y-%m-%dT%H:%M:%SZ)'"
# }] }]
# }' \ }' \
# ${{ secrets.DISCORD_WEBHOOK }} ${{ secrets.DISCORD_WEBHOOK }}