Update deploy.yml

This commit is contained in:
Vaica committed 2026-06-25 16:17:35 +08:00
1 parent ed40eef2b3
commit 8c29c44bc0
1 file changed
+187 -67
+187 -67
View File
@@ -554,43 +554,73 @@ jobs:
if [ "$EDGEONE_DEPLOYED" = "true" ]; then if [ "$EDGEONE_DEPLOYED" = "true" ]; then
EDGEONE_DOWNLOAD="${{ needs.deploy-edgeone.outputs.download_duration }}" EDGEONE_DOWNLOAD="${{ needs.deploy-edgeone.outputs.download_duration }}"
EDGEONE_UPLOAD="${{ needs.deploy-edgeone.outputs.upload_duration }}" EDGEONE_UPLOAD="${{ needs.deploy-edgeone.outputs.upload_duration }}"
EDGEONE_DETAIL=$(printf "\n - 下载: %ss\n - 上传: %ss" "$EDGEONE_DOWNLOAD" "$EDGEONE_UPLOAD") EDGEONE_DETAIL=$(printf "\n 📥 下载: %ss\n 📤 上传: %ss" "$EDGEONE_DOWNLOAD" "$EDGEONE_UPLOAD")
fi fi
UPYUN_DETAIL="" UPYUN_DETAIL=""
if [ "$UPYUN_DEPLOYED" = "true" ]; then if [ "$UPYUN_DEPLOYED" = "true" ]; then
UPYUN_DOWNLOAD="${{ needs.deploy-upyun.outputs.download_duration }}" UPYUN_DOWNLOAD="${{ needs.deploy-upyun.outputs.download_duration }}"
UPYUN_UPLOAD="${{ needs.deploy-upyun.outputs.upload_duration }}" UPYUN_UPLOAD="${{ needs.deploy-upyun.outputs.upload_duration }}"
UPYUN_DETAIL=$(printf "\n - 下载: %ss\n - 上传: %ss" "$UPYUN_DOWNLOAD" "$UPYUN_UPLOAD") UPYUN_DETAIL=$(printf "\n 📥 下载: %ss\n 📤 上传: %ss" "$UPYUN_DOWNLOAD" "$UPYUN_UPLOAD")
fi fi
if [ "${{ steps.deploy-status.outputs.any_deployed }}" = "true" ]; then if [ "${{ steps.deploy-status.outputs.any_deployed }}" = "true" ]; then
TITLE="✅ **部署成功**" STATUS_ICON="🎉"
STATUS_TEXT="部署成功"
else else
TITLE="ℹ️ **无变化,跳过部署**" STATUS_ICON="⏭️"
STATUS_TEXT="无变化,跳过部署"
fi fi
MESSAGE=$(printf "%s\n\n📦 项目: %s\n🌿 分支: %s\n🔗 Commit: %s\n🕐 时间: %s\n\n📊 构建统计:\n- 文件总数: %s\n- 总大小: %s\n\n⏱️ 耗时统计:\n- Pre-check: %ss\n- Build: %ss\n- EdgeOne: %ss%s\n- UpYun: %ss%s\n\n🔍 查看详情: https://github.com/%s/actions/runs/%s" \ EDGEONE_STATUS=$([ "$EDGEONE_DEPLOYED" = "true" ] && echo "✅ 已部署" || echo "⏭️ 跳过")
"$TITLE" \ UPYUN_STATUS=$([ "$UPYUN_DEPLOYED" = "true" ] && echo "✅ 已部署" || echo "⏭️ 跳过")
MESSAGE=$(printf "%s *%s*\n\n\
📦 *项目*: \`%s\`\n\
🌿 *分支*: \`%s\`\n\
🔗 *Commit*: \`%s\`\n\
⏰ *时间*: %s\n\
🚀 *触发方式*: %s\n\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
📊 *构建统计*\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
📁 文件总数: %s\n\
💾 总大小: %s\n\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
⏱️ *耗时统计*\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
🔍 Pre-check: %ss\n\
🏗️ Build: %ss\n\
🌐 EdgeOne: %ss%s\n\
☁️ UpYun: %ss%s\n\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
📌 *部署状态*\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
🌐 EdgeOne Pages: %s\n\
☁️ UpYun: %s\n\n\
� [查看详情](https://github.com/%s/actions/runs/%s)" \
"$STATUS_ICON" "$STATUS_TEXT" \
"${{ github.repository }}" \ "${{ github.repository }}" \
"${{ github.ref_name }}" \ "${{ github.ref_name }}" \
"${{ github.sha }}" \ "${{ github.sha }}" \
"$(date +'%Y-%m-%d %H:%M:%S')" \ "$(date +'%Y-%m-%d %H:%M:%S')" \
"${{ github.event_name }}" \
"$FILE_COUNT" \ "$FILE_COUNT" \
"$TOTAL_SIZE" \ "$TOTAL_SIZE" \
"$PRECHECK_DUR" \ "$PRECHECK_DUR" \
"$BUILD_DUR" \ "$BUILD_DUR" \
"$EDGEONE_DUR" \ "$EDGEONE_DUR" "$EDGEONE_DETAIL" \
"$EDGEONE_DETAIL" \ "$UPYUN_DUR" "$UPYUN_DETAIL" \
"$UPYUN_DUR" \ "$EDGEONE_STATUS" \
"$UPYUN_DETAIL" \ "$UPYUN_STATUS" \
"${{ github.repository }}" \ "${{ github.repository }}" \
"${{ github.run_id }}") "${{ github.run_id }}")
curl -s -X POST "https://api.telegram.org/bot${TELEGRAM_BOT_TOKEN}/sendMessage" \ curl -s -X POST "https://api.telegram.org/bot${TELEGRAM_BOT_TOKEN}/sendMessage" \
-d chat_id="${TELEGRAM_CHAT_ID}" \ -d chat_id="${TELEGRAM_CHAT_ID}" \
-d text="$MESSAGE" \ -d text="$MESSAGE" \
-d parse_mode="Markdown" -d parse_mode="Markdown" \
-d disable_web_page_preview=true
- name: Send Feishu notification with detailed timing - name: Send Feishu notification with detailed timing
env: env:
@@ -614,36 +644,65 @@ jobs:
if [ "$EDGEONE_DEPLOYED" = "true" ]; then if [ "$EDGEONE_DEPLOYED" = "true" ]; then
EDGEONE_DOWNLOAD="${{ needs.deploy-edgeone.outputs.download_duration }}" EDGEONE_DOWNLOAD="${{ needs.deploy-edgeone.outputs.download_duration }}"
EDGEONE_UPLOAD="${{ needs.deploy-edgeone.outputs.upload_duration }}" EDGEONE_UPLOAD="${{ needs.deploy-edgeone.outputs.upload_duration }}"
EDGEONE_DETAIL=$(printf "\\n - 下载: %ss\\n - 上传: %ss" "$EDGEONE_DOWNLOAD" "$EDGEONE_UPLOAD") EDGEONE_DETAIL=$(printf "\n 📥 下载: %ss\n 📤 上传: %ss" "$EDGEONE_DOWNLOAD" "$EDGEONE_UPLOAD")
fi fi
UPYUN_DETAIL="" UPYUN_DETAIL=""
if [ "$UPYUN_DEPLOYED" = "true" ]; then if [ "$UPYUN_DEPLOYED" = "true" ]; then
UPYUN_DOWNLOAD="${{ needs.deploy-upyun.outputs.download_duration }}" UPYUN_DOWNLOAD="${{ needs.deploy-upyun.outputs.download_duration }}"
UPYUN_UPLOAD="${{ needs.deploy-upyun.outputs.upload_duration }}" UPYUN_UPLOAD="${{ needs.deploy-upyun.outputs.upload_duration }}"
UPYUN_DETAIL=$(printf "\\n - 下载: %ss\\n - 上传: %ss" "$UPYUN_DOWNLOAD" "$UPYUN_UPLOAD") UPYUN_DETAIL=$(printf "\n 📥 下载: %ss\n 📤 上传: %ss" "$UPYUN_DOWNLOAD" "$UPYUN_UPLOAD")
fi fi
if [ "${{ steps.deploy-status.outputs.any_deployed }}" = "true" ]; then if [ "${{ steps.deploy-status.outputs.any_deployed }}" = "true" ]; then
TITLE="✅ **部署成功**" STATUS_ICON="🎉"
STATUS_TEXT="部署成功"
else else
TITLE="ℹ️ **无变化,跳过部署**" STATUS_ICON="⏭️"
STATUS_TEXT="无变化,跳过部署"
fi fi
MESSAGE_TEXT=$(printf "%s\n\n📦 项目: %s\n🌿 分支: %s\n🔗 Commit: %s\n🕐 时间: %s\n\n📊 构建统计:\n- 文件总数: %s\n- 总大小: %s\n\n⏱️ 耗时统计:\n- Pre-check: %ss\n- Build: %ss\n- EdgeOne: %ss%s\n- UpYun: %ss%s\n\n🔍 查看详情: https://github.com/%s/actions/runs/%s" \ EDGEONE_STATUS=$([ "$EDGEONE_DEPLOYED" = "true" ] && echo "✅ 已部署" || echo "⏭️ 跳过")
"$TITLE" \ UPYUN_STATUS=$([ "$UPYUN_DEPLOYED" = "true" ] && echo "✅ 已部署" || echo "⏭️ 跳过")
MESSAGE_TEXT=$(printf "%s %s\n\n\
📦 项目: %s\n\
🌿 分支: %s\n\
🔗 Commit: %s\n\
⏰ 时间: %s\n\
🚀 触发方式: %s\n\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
📊 构建统计\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
📁 文件总数: %s\n\
💾 总大小: %s\n\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
⏱️ 耗时统计\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
🔍 Pre-check: %ss\n\
🏗️ Build: %ss\n\
🌐 EdgeOne: %ss%s\n\
☁️ UpYun: %ss%s\n\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
📌 部署状态\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
🌐 EdgeOne Pages: %s\n\
☁️ UpYun: %s\n\n\
� 查看详情: https://github.com/%s/actions/runs/%s" \
"$STATUS_ICON" "$STATUS_TEXT" \
"${{ github.repository }}" \ "${{ github.repository }}" \
"${{ github.ref_name }}" \ "${{ github.ref_name }}" \
"${{ github.sha }}" \ "${{ github.sha }}" \
"$(date +'%Y-%m-%d %H:%M:%S')" \ "$(date +'%Y-%m-%d %H:%M:%S')" \
"${{ github.event_name }}" \
"$FILE_COUNT" \ "$FILE_COUNT" \
"$TOTAL_SIZE" \ "$TOTAL_SIZE" \
"$PRECHECK_DUR" \ "$PRECHECK_DUR" \
"$BUILD_DUR" \ "$BUILD_DUR" \
"$EDGEONE_DUR" \ "$EDGEONE_DUR" "$EDGEONE_DETAIL" \
"$EDGEONE_DETAIL" \ "$UPYUN_DUR" "$UPYUN_DETAIL" \
"$UPYUN_DUR" \ "$EDGEONE_STATUS" \
"$UPYUN_DETAIL" \ "$UPYUN_STATUS" \
"${{ github.repository }}" \ "${{ github.repository }}" \
"${{ github.run_id }}") "${{ github.run_id }}")
@@ -670,50 +729,50 @@ jobs:
secure: true secure: true
username: ${{ secrets.MAIL_USERNAME }} username: ${{ secrets.MAIL_USERNAME }}
password: ${{ secrets.MAIL_PASSWORD }} password: ${{ secrets.MAIL_PASSWORD }}
subject: "[部署报告] ${{ github.repository }} - ${{ steps.date.outputs.date }}" subject: "🎉 部署成功 - ${{ github.repository }} - ${{ steps.date.outputs.date }}"
to: ${{ secrets.MAIL_USERNAME }} to: ${{ secrets.MAIL_USERNAME }}
from: GitHub Actions <${{ github.event_name }}> from: GitHub Actions <${{ github.event_name }}>
body: | body: |
=========================================== 🎉 部署成功 🎉
部署报告 ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
===========================================
项目: ${{ github.repository }}
分支: ${{ github.ref_name }}
Commit: ${{ github.sha }}
时间: ${{ steps.date.outputs.date }}
触发方式: ${{ github.event_name }}
=========================================== 📦 项目信息
构建统计 ──────────────────────────────────
=========================================== 项目: ${{ github.repository }}
文件总数: ${{ needs.build.outputs.file_count }} 分支: ${{ github.ref_name }}
总大小: ${{ needs.build.outputs.total_size }} Commit: ${{ github.sha }}
⏰ 时间: ${{ steps.date.outputs.date }}
🚀 触发方式: ${{ github.event_name }}
=========================================== 📊 构建统计
耗时统计 ──────────────────────────────────
=========================================== 📁 文件总数: ${{ needs.build.outputs.file_count }}
Pre-check: ${{ needs.pre-check.outputs.duration }}s 💾 总大小: ${{ needs.build.outputs.total_size }}
Build: ${{ needs.build.outputs.duration }}s
EdgeOne Pages: ${{ needs.deploy-edgeone.outputs.duration }}s ⏱️ 耗时统计
- 下载 Artifact: ${{ needs.deploy-edgeone.outputs.download_duration }}s ──────────────────────────────────
- 上传部署: ${{ needs.deploy-edgeone.outputs.upload_duration }}s 🔍 Pre-check: ${{ needs.pre-check.outputs.duration }}s
🏗️ Build: ${{ needs.build.outputs.duration }}s
UpYun: ${{ needs.deploy-upyun.outputs.duration }}s 🌐 EdgeOne Pages: ${{ needs.deploy-edgeone.outputs.duration }}s
- 下载 Artifact: ${{ needs.deploy-upyun.outputs.download_duration }}s 📥 下载 Artifact: ${{ needs.deploy-edgeone.outputs.download_duration }}s
- 上传部署: ${{ needs.deploy-upyun.outputs.upload_duration }}s 📤 上传部署: ${{ needs.deploy-edgeone.outputs.upload_duration }}s
=========================================== ☁️ UpYun: ${{ needs.deploy-upyun.outputs.duration }}s
部署状态 📥 下载 Artifact: ${{ needs.deploy-upyun.outputs.download_duration }}s
=========================================== 📤 上传部署: ${{ needs.deploy-upyun.outputs.upload_duration }}s
EdgeOne Pages: ${{ needs.deploy-edgeone.outputs.deployed == 'true' && '已部署' || '跳过(无变化)' }}
UpYun: ${{ needs.deploy-upyun.outputs.deployed == 'true' && '已部署' || '跳过(无变化)' }}
=========================================== 📌 部署状态
查看详情 ──────────────────────────────────
=========================================== 🌐 EdgeOne Pages: ${{ needs.deploy-edgeone.outputs.deployed == 'true' && '✅ 已部署' || '⏭️ 跳过(无变化)' }}
☁️ UpYun: ${{ needs.deploy-upyun.outputs.deployed == 'true' && '✅ 已部署' || '⏭️ 跳过(无变化)' }}
🔗 查看详情
──────────────────────────────────
https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }} https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
- name: Generate timing summary - name: Generate timing summary
id: timing-summary id: timing-summary
run: | run: |
@@ -797,25 +856,56 @@ jobs:
fi fi
FAILURES="" FAILURES=""
if [ "${{ needs.pre-check.result }}" = "failure" ]; then FAILURES=$(printf "%s\n- ❌ Pre-check" "$FAILURES"); fi if [ "${{ needs.pre-check.result }}" = "failure" ]; then FAILURES=$(printf "%s\n 🔴 Pre-check" "$FAILURES"); fi
if [ "${{ needs.build.result }}" = "failure" ]; then FAILURES=$(printf "%s\n- ❌ Build" "$FAILURES"); fi if [ "${{ needs.build.result }}" = "failure" ]; then FAILURES=$(printf "%s\n 🔴 Build" "$FAILURES"); fi
if [ "${{ needs.deploy-edgeone.result }}" = "failure" ]; then FAILURES=$(printf "%s\n- ❌ Deploy EdgeOne" "$FAILURES"); fi if [ "${{ needs.deploy-edgeone.result }}" = "failure" ]; then FAILURES=$(printf "%s\n 🔴 Deploy EdgeOne" "$FAILURES"); fi
if [ "${{ needs.deploy-upyun.result }}" = "failure" ]; then FAILURES=$(printf "%s\n- ❌ Deploy UpYun" "$FAILURES"); fi if [ "${{ needs.deploy-upyun.result }}" = "failure" ]; then FAILURES=$(printf "%s\n 🔴 Deploy UpYun" "$FAILURES"); fi
if [ "${{ needs.finalize.result }}" = "failure" ]; then FAILURES=$(printf "%s\n- ❌ Finalize" "$FAILURES"); fi if [ "${{ needs.finalize.result }}" = "failure" ]; then FAILURES=$(printf "%s\n 🔴 Finalize" "$FAILURES"); fi
MESSAGE=$(printf "❌ **部署失败**\n\n📦 项目: %s\n🌿 分支: %s\n🔗 Commit: %s\n🕐 时间: %s\n\n⚠️ 失败阶段:%s\n\n🔍 查看详情: https://github.com/%s/actions/runs/%s" \ # 检查每个阶段的状态
PRECHECK_STATUS=$([ "${{ needs.pre-check.result }}" = "success" ] && echo "✅ 成功" || ([ "${{ needs.pre-check.result }}" = "failure" ] && echo "❌ 失败" || echo "⏭️ 跳过"))
BUILD_STATUS=$([ "${{ needs.build.result }}" = "success" ] && echo "✅ 成功" || ([ "${{ needs.build.result }}" = "failure" ] && echo "❌ 失败" || echo "⏭️ 跳过"))
EDGEONE_STATUS=$([ "${{ needs.deploy-edgeone.result }}" = "success" ] && echo "✅ 成功" || ([ "${{ needs.deploy-edgeone.result }}" = "failure" ] && echo "❌ 失败" || echo "⏭️ 跳过"))
UPYUN_STATUS=$([ "${{ needs.deploy-upyun.result }}" = "success" ] && echo "✅ 成功" || ([ "${{ needs.deploy-upyun.result }}" = "failure" ] && echo "❌ 失败" || echo "⏭️ 跳过"))
FINALIZE_STATUS=$([ "${{ needs.finalize.result }}" = "success" ] && echo "✅ 成功" || ([ "${{ needs.finalize.result }}" = "failure" ] && echo "❌ 失败" || echo "⏭️ 跳过"))
MESSAGE=$(printf "💥 *部署失败*\n\n\
📦 *项目*: \`%s\`\n\
🌿 *分支*: \`%s\`\n\
🔗 *Commit*: \`%s\`\n\
⏰ *时间*: %s\n\
🚀 *触发方式*: %s\n\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
⚠️ *失败阶段*\n\
━━━━━━━━━━━━━━━━━━━━━━%s\n\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
📊 *各阶段状态*\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
🔍 Pre-check: %s\n\
🏗️ Build: %s\n\
🌐 Deploy EdgeOne: %s\n\
☁️ Deploy UpYun: %s\n\
📤 Finalize: %s\n\n\
� [查看详情](https://github.com/%s/actions/runs/%s)" \
"${{ github.repository }}" \ "${{ github.repository }}" \
"${{ github.ref_name }}" \ "${{ github.ref_name }}" \
"${{ github.sha }}" \ "${{ github.sha }}" \
"$(date +'%Y-%m-%d %H:%M:%S')" \ "$(date +'%Y-%m-%d %H:%M:%S')" \
"${{ github.event_name }}" \
"$FAILURES" \ "$FAILURES" \
"$PRECHECK_STATUS" \
"$BUILD_STATUS" \
"$EDGEONE_STATUS" \
"$UPYUN_STATUS" \
"$FINALIZE_STATUS" \
"${{ github.repository }}" \ "${{ github.repository }}" \
"${{ github.run_id }}") "${{ github.run_id }}")
curl -s -X POST "https://api.telegram.org/bot${TELEGRAM_BOT_TOKEN}/sendMessage" \ curl -s -X POST "https://api.telegram.org/bot${TELEGRAM_BOT_TOKEN}/sendMessage" \
-d chat_id="${TELEGRAM_CHAT_ID}" \ -d chat_id="${TELEGRAM_CHAT_ID}" \
-d text="$MESSAGE" \ -d text="$MESSAGE" \
-d parse_mode="Markdown" -d parse_mode="Markdown" \
-d disable_web_page_preview=true
- name: Send Feishu failure notification - name: Send Feishu failure notification
env: env:
@@ -827,18 +917,48 @@ jobs:
fi fi
FAILURES="" FAILURES=""
if [ "${{ needs.pre-check.result }}" = "failure" ]; then FAILURES=$(printf "%s\n- ❌ Pre-check" "$FAILURES"); fi if [ "${{ needs.pre-check.result }}" = "failure" ]; then FAILURES=$(printf "%s\n 🔴 Pre-check" "$FAILURES"); fi
if [ "${{ needs.build.result }}" = "failure" ]; then FAILURES=$(printf "%s\n- ❌ Build" "$FAILURES"); fi if [ "${{ needs.build.result }}" = "failure" ]; then FAILURES=$(printf "%s\n 🔴 Build" "$FAILURES"); fi
if [ "${{ needs.deploy-edgeone.result }}" = "failure" ]; then FAILURES=$(printf "%s\n- ❌ Deploy EdgeOne" "$FAILURES"); fi if [ "${{ needs.deploy-edgeone.result }}" = "failure" ]; then FAILURES=$(printf "%s\n 🔴 Deploy EdgeOne" "$FAILURES"); fi
if [ "${{ needs.deploy-upyun.result }}" = "failure" ]; then FAILURES=$(printf "%s\n- ❌ Deploy UpYun" "$FAILURES"); fi if [ "${{ needs.deploy-upyun.result }}" = "failure" ]; then FAILURES=$(printf "%s\n 🔴 Deploy UpYun" "$FAILURES"); fi
if [ "${{ needs.finalize.result }}" = "failure" ]; then FAILURES=$(printf "%s\n- ❌ Finalize" "$FAILURES"); fi if [ "${{ needs.finalize.result }}" = "failure" ]; then FAILURES=$(printf "%s\n 🔴 Finalize" "$FAILURES"); fi
MESSAGE_TEXT=$(printf "❌ **部署失败**\n\n📦 项目: %s\n🌿 分支: %s\n🔗 Commit: %s\n🕐 时间: %s\n\n⚠️ 失败阶段:%s\n\n🔍 查看详情: https://github.com/%s/actions/runs/%s" \ # 检查每个阶段的状态
PRECHECK_STATUS=$([ "${{ needs.pre-check.result }}" = "success" ] && echo "✅ 成功" || ([ "${{ needs.pre-check.result }}" = "failure" ] && echo "❌ 失败" || echo "⏭️ 跳过"))
BUILD_STATUS=$([ "${{ needs.build.result }}" = "success" ] && echo "✅ 成功" || ([ "${{ needs.build.result }}" = "failure" ] && echo "❌ 失败" || echo "⏭️ 跳过"))
EDGEONE_STATUS=$([ "${{ needs.deploy-edgeone.result }}" = "success" ] && echo "✅ 成功" || ([ "${{ needs.deploy-edgeone.result }}" = "failure" ] && echo "❌ 失败" || echo "⏭️ 跳过"))
UPYUN_STATUS=$([ "${{ needs.deploy-upyun.result }}" = "success" ] && echo "✅ 成功" || ([ "${{ needs.deploy-upyun.result }}" = "failure" ] && echo "❌ 失败" || echo "⏭️ 跳过"))
FINALIZE_STATUS=$([ "${{ needs.finalize.result }}" = "success" ] && echo "✅ 成功" || ([ "${{ needs.finalize.result }}" = "failure" ] && echo "❌ 失败" || echo "⏭️ 跳过"))
MESSAGE_TEXT=$(printf "💥 部署失败\n\n\
📦 项目: %s\n\
🌿 分支: %s\n\
🔗 Commit: %s\n\
⏰ 时间: %s\n\
🚀 触发方式: %s\n\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
⚠️ 失败阶段\n\
━━━━━━━━━━━━━━━━━━━━━━%s\n\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
📊 各阶段状态\n\
━━━━━━━━━━━━━━━━━━━━━━\n\
🔍 Pre-check: %s\n\
🏗️ Build: %s\n\
🌐 Deploy EdgeOne: %s\n\
☁️ Deploy UpYun: %s\n\
📤 Finalize: %s\n\n\
� 查看详情: https://github.com/%s/actions/runs/%s" \
"${{ github.repository }}" \ "${{ github.repository }}" \
"${{ github.ref_name }}" \ "${{ github.ref_name }}" \
"${{ github.sha }}" \ "${{ github.sha }}" \
"$(date +'%Y-%m-%d %H:%M:%S')" \ "$(date +'%Y-%m-%d %H:%M:%S')" \
"${{ github.event_name }}" \
"$FAILURES" \ "$FAILURES" \
"$PRECHECK_STATUS" \
"$BUILD_STATUS" \
"$EDGEONE_STATUS" \
"$UPYUN_STATUS" \
"$FINALIZE_STATUS" \
"${{ github.repository }}" \ "${{ github.repository }}" \
"${{ github.run_id }}") "${{ github.run_id }}")