feat: 发布成功/失败飞书&Lark 群卡片通知
- internal/lark:飞书自定义机器人交互卡片(wide_screen_mode + 彩色头部 green/red/yellow + lark_md 字段区 + 查看构建详情按钮),支持签名加签 (timestamp+sign HMAC-SHA256,密钥 enc:v1: 加密存储) - 双引擎收口:原生模拟引擎与 Jenkins 真实引擎运行结束均推送卡片; 应用/分支/构建(#N 或 runId)/状态/时间;Jenkins 构建附 externalURL 按钮直达构建详情页 - Webhook 优先级:流水线「通知 Webhook」> 全局设置(需启用) - 系统设置新增飞书通知配置区(启用开关/Webhook/签名密钥只写/ 发送测试卡片);POST /api/settings/test-lark - E2E 已验证:本地模拟机器人收到完整卡片 JSON,测试卡片正常
This commit is contained in:
1 parent
6e97b55015
commit
d9d1dd5e99
10 files changed
+329
-9
No files matched your search
@@ -274,6 +274,10 @@ type SystemSetting struct {
|
||||
LlmApiKey string `gorm:"type:text" json:"-"` // enc:v1: 加密,只写不读
|
||||
LlmApiKeySet bool `gorm:"-" json:"llmApiKeySet"`
|
||||
LlmMaxTokens int `gorm:"default:1200" json:"llmMaxTokens"`
|
||||
LarkEnabled bool `gorm:"default:false" json:"larkEnabled"`
|
||||
LarkWebhook string `json:"larkWebhook"` // 飞书群自定义机器人 Webhook
|
||||
LarkSecret string `gorm:"type:text" json:"-"` // 加签密钥(可选),enc:v1: 加密
|
||||
LarkSecretSet bool `gorm:"-" json:"larkSecretSet"`
|
||||
Extra string `gorm:"type:text" json:"extra"`
|
||||
UpdatedAt time.Time `json:"updatedAt"`
|
||||
}
|
||||
Reference in new issue
Block a user