This commit is contained in:
master of disaster
2026-06-12 10:21:54 +02:00
parent ec4ceadd5d
commit d4842867b2

View File

@@ -42,6 +42,10 @@ on:
secrets:
TOKEN:
required: true
TELEGRAM_BOT_TOKEN:
required: false
TELEGRAM_CHAT_ID:
required: false
# Optional — override default REGISTRY_USER/REGISTRY_PASSWORD
REGISTRY_USER_OVERRIDE:
required: false
@@ -113,7 +117,6 @@ jobs:
- name: 🔨 Build + Push Image
run: |
# Build extra destinations
DESTINATIONS="--destination ${{ steps.meta.outputs.tag_latest }} \
--destination ${{ steps.meta.outputs.tag_sha }}"
@@ -126,7 +129,8 @@ jobs:
NO_CACHE="--no-push-cache --cache=false"
fi
/kaniko/executor \
# Kaniko executor is in /tools (copied by initContainer)
/tools/executor \
--context=dir:///workspace/${{ inputs.context_path }} \
--dockerfile=/workspace/${{ inputs.dockerfile_path }} \
${DESTINATIONS} \
@@ -141,8 +145,7 @@ jobs:
STATUS="${{ job.status }}"
IMAGE="${{ steps.meta.outputs.tag_latest }}"
SHA="${{ steps.meta.outputs.short_sha }}"
TEXT="🏗️ Image Build: ${IMAGE}%0ASHA: ${SHA}%0AStatus: ${STATUS}"
curl -s -X POST \
"https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendMessage" \
-d "chat_id=${{ secrets.TELEGRAM_CHAT_ID }}" \
-d "text=${TEXT}"
# Use wget — available in gitea/act_runner base image (busybox)
wget -q -O- \
--post-data="chat_id=${{ secrets.TELEGRAM_CHAT_ID }}&text=🏗️ Build: ${IMAGE} SHA:${SHA} Status:${STATUS}" \
"https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendMessage" || true