Skip to content

Commit fd941d7

Browse files
committed
feat: send notification to feishu on ci failure
EE-18909
1 parent ac24285 commit fd941d7

File tree

1 file changed

+17
-1
lines changed

1 file changed

+17
-1
lines changed

.github/workflows/update.yml

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Incremental Build Triggered By Push Events
1+
name: Incremental Build Website Docs Triggered By Push Events
22

33
on: repository_dispatch
44

@@ -186,3 +186,19 @@ jobs:
186186
if: github.event.client_payload.download_type == 'full'
187187
run: |
188188
bash ./scripts/get-latest-commits.sh ${{ secrets.GH_TOKEN }}
189+
190+
notify-feishu-on-failure:
191+
name: Notify Feishu on Failure
192+
runs-on: ubuntu-latest
193+
if: failure()
194+
steps:
195+
- name: Send notification to Feishu on failure
196+
run: |
197+
curl -X POST ${{ secrets.FEISHU_CI_BOT_WEBHOOK_URL }} \
198+
-H 'Content-Type: application/json' \
199+
-d '{
200+
"msg_type": "text",
201+
"content": {
202+
"text": "🚨 GitHub Action 失败通知:官网文档部署失败!\n- 仓库: ${{ github.repository }}\n- 分支: ${{ github.ref }}\n- 工作流: ${{ github.workflow }}\n- 触发人: ${{ github.actor }}\n- 详情: ${{ github.event.head_commit.message }}\n- [查看日志](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})"
203+
}
204+
}'

0 commit comments

Comments
 (0)