.gitea/workflows/create_and_push_multiarch_container.yml aktualisiert
All checks were successful
build-image / release-image (push) Successful in 8m25s
build-image / telegram-notify (push) Successful in 2s

This commit is contained in:
2026-03-20 19:26:42 +01:00
parent fcd1ee55a8
commit a0378bad9c

View File

@@ -48,3 +48,30 @@ jobs:
--tag ${{ env.user }}/${{ env.image_name }}:latest \
--tag ${{ env.user }}/${{ env.image_name }}:${{ github.ref_name }} \
--push ./
telegram-notify:
needs: release-image
if: always()
runs-on: ubuntu-latest
steps:
- name: Telegram Alert
run: |
case "${{ needs.release-image.result }}" in
"success") EMOJI="✅"; MSG="OK" ;;
"failure") EMOJI="❌"; MSG="WARN!" ;;
"cancelled") EMOJI="⏹️"; MSG="Canceled" ;;
*) EMOJI="❓"; MSG="Unknown-State: ${{ needs.release-image.result }}" ;;
esac
curl -s -X POST "https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendMessage" \
-H 'Content-Type: application/json' \
-d "{
\"chat_id\": \"${{ secrets.TELEGRAM_CHAT_ID }}\",
\"parse_mode\": \"HTML\",
\"text\":
\"$EMOJI <b>$MSG - Build ${{ env.image_name }}:${{ github.ref_name }}</b>
<i>$(date +"%Y-%m-%d %T")</i>
Build of Image: <b><i>${{ env.image_name }}:${{ github.ref_name }}</i></b>
${{ gitea.server_url }}/${{ gitea.repository }}
\"
}"