Files
code_scan/config.yaml
Dang Zerong 17306c6814 init
2026-03-10 17:22:07 +08:00

60 lines
1.9 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

server:
host: "0.0.0.0"
port: 5000
debug: true
gitea:
# Gitea 服务器地址(根据实际情况修改)
base_url: "http://154.9.253.114:3000"
# Gitea Webhook 签名密钥,需要与 Gitea 配置一致
webhook_secret: "BoschScan_2026_xxx"
feishu:
# 飞书机器人 Webhook 地址(替换为你的实际地址)
#webhook_url: "https://open.feishu.cn/open-apis/bot/v2/hook/636258bb-5f6e-40aa-aca3-10e61381325e"
# 飞书消息签名密钥(可选)
secret: ""
# 飞书应用配置(用于发送文件)
# 如果需要发送文件,需要在飞书开放平台创建应用并获取以下配置
app_id: "cli_a9256d9d657b9bce"
app_secret: "4rsELdjStVuWnklxn0PLDbC0WPrSaKyN"
# 发送目标的群聊 ID应用机器人发送文件需要群聊 ID
# 在群聊中添加机器人后,使用 https://open.feishu.cn/document/ukTMukTMukTM/uADOwUjLwgDM14CM4ATN 获取群 ID
chat_id: "oc_313d71d460a851f31b7ddd0aca14c5b0"
# 是否在通知中附加报告文件
attach_report_file: true
scanner:
# 支持的编程语言
languages:
- python
- javascript
- typescript
# 最大问题数量阈值,超过则标记为失败
max_issues: 10
# 是否启用详细扫描模式
detailed: true
# 克隆代码仓库的临时目录
temp_clone_dir: "/tmp/code_scanner_clones"
report:
# 报告保存目录
output_dir: "./reports"
# 是否保留报告文件
keep_files: true
ai:
# AI 审查器配置
# 支持: "ollama" (本地) 或 "api" (在线API)
provider: "api"
# 模型名称(硅基流动可用模型)
model: "Qwen/Qwen2.5-7B-Instruct"
# API 地址
# 硅基流动: https://api.siliconflow.cn/v1
api_url: "https://api.siliconflow.cn/v1"
# API 密钥
api_key: "sk-cqxhnsxdxaalxlykfkjksyinjftdyejnblmgkfxmhwmmvdyu"
# 是否启用 AI 审查
enabled: true
# 每次审查的最大代码行数
max_lines: 200