chavatte/sentinel-ops
GitHub: chavatte/sentinel-ops
专为Node.js生态设计的持续依赖安全审计工具,通过自动化CVE检测和供应链监控帮助团队持续追踪仓库依赖的安全风险。
Stars: 0 | Forks: 0
\\\\\\
\\\\\\\\\\\\
\\\\\\\\\\\\\\\
-------------,-| |C> // )\\\\| .o88b. db db .d8b. db db .d8b. d888888b d888888b d88888b
,','| / || ,'/////| d8P Y8 88 88 d8' '8b 88 88 d8' '8b '~~88~~' '~~88~~' 88'
---------,',' | (, || ///// 8P 88ooo88 88ooo88 Y8 8P 88ooo88 88 88 88ooooo
|| | \\ ||||//''''| 8b 88~~~88 88~~~88 '8b d8' 88~~~88 88 88 88~~~~~
|| | ||||||| _| Y8b d8 88 88 88 88 '8bd8' 88 88 88 88 88.
|| |______ ''''\____/ \ 'Y88P' YP YP YP YP YP YP YP YP YP Y88888P
|| | ,| _/_____/ \
|| ,' ,' | / | ___________________________________________
||,' ,' | | \ | / \ \
_________|/ ,' | / | | | | |
_____________,' ,',_____| | | | \ | chavatte@duck.com |
| ,',' | | | | | chavatte.vercel.app |
| ,',' ____|_____/ / | | ________________________________________|___
| ,',' __/ | / | | / /
_____________|',' ///_/-------------/ | \_/____________________________________________/
|===========,'
# 🛡️ Sentinel 运维
[](README.pt-br.md)



**Sentinel Ops** 是一款专为家庭实验室、CasaOS 服务器以及 DevOps/SecOps 团队设计的持续安全审计工具。它能自动监控你的 Git 仓库,检查过时的依赖项,并通过响应式赛博朋克界面报告安全漏洞(CVEs/GHSAs)。
## ✨ 功能特性
* **🕵️♂️ 通用性:** 自动检测并审计 **NPM**、**Yarn (Classic & Berry v4+)** 和 **PNPM** 项目。
* **📡 OSV-Scanner 集成:** 由 Google 的 OSV 数据库提供支持,检测原生审计遗漏的跨生态系统漏洞。
* **🎯 威胁情报:** 内置智能链接,直接指向确切的公告(NIST NVD、GitHub Advisories、OSV),以便快速缓解威胁。
* **⚡ 超快速度(Sparse Checkout):** 不克隆整个仓库。仅下载清单文件(`package.json`、`lockfiles`),节省带宽和存储空间。
* **🔒 安全性:** 在隔离的容器中运行,无对远程仓库的写入权限。
* **🖥️ 可视化仪表板:** 响应式 Web UI,具备暗黑模式、实时更新、来源徽章和风险详情。
* **🐳 Docker 原生支持:** 可直接用于 Docker Compose、CasaOS 或 Portainer。
* **🔑 混合支持:** 同时支持私有仓库(通过 SSH)和公共仓库(通过 HTTPS)。
## 🚀 快速安装(Docker Compose)
### 1. 文件夹结构
使用以下结构创建一个项目文件夹:
```
/sentinel-ops
├── docker-compose.yml
├── ssh/ # (Optional) Your private SSH keys
└── config/
└── repos.yml # Repository list
```
### 2. 配置(`docker-compose.yml`)
**YAML**
```
version: "3.8"
services:
sentinel-ops:
image: chavatte/sentinel-ops:latest
container_name: sentinel-ops
restart: unless-stopped
ports:
- "8080:8080"
dns:
- 8.8.8.8
- 1.1.1.1
environment:
- SCAN_INTERVAL=21600 # Time in seconds (6 hours)
- TZ=America/Sao_Paulo
volumes:
- ./config/repos.yml:/config/repos.yml:ro
- ./ssh:/ssh:ro
- sentinel_data:/data
volumes:
sentinel_data:
```
### 3. 定义仓库(`config/repos.yml`)
创建 `config/repos.yml`。你可以混合使用私有和公共仓库。
**YAML**
```
repos:
# 🔐 Private Repo (Requires key in ./ssh folder)
- id: my-saas
name: "My Private SaaS"
git: git@github.com:user/secret-project.git
ssh_key: /ssh/id_rsa
# 🌍 Public Repo (No key needed)
- id: react-core
name: "React (Open Source)"
git: [https://github.com/facebook/react.git](https://github.com/facebook/react.git)
```
### 4. 运行
**Bash**
```
docker compose up -d
```
访问仪表板:`http://localhost:8080`
## 🔑 SSH 配置(用于私有仓库)
如果你需要审计私有仓库(GitHub、GitLab、Bitbucket):
1. 将你的私钥(例如 `id_rsa`)复制到你创建的 `./ssh` 文件夹中。
2. 在 `repos.yml` 中,`ssh_key` 字段必须指向 `/ssh/filename`。
3. **安全性:** Sentinel Ops 会在执行期间自动将你的密钥复制到安全的临时区域并应用受限权限(`chmod 600`)。
## 🛠️ 开发(手动)
要在 Docker 外部运行或贡献代码:
**前置条件:** 已安装 Python 3.11+、Git、Node.js、Corepack (Yarn/PNPM) 和 OSV-Scanner。
1. 克隆此仓库。
2. 安装 Python 依赖:
**Bash**
pip install -r requirements.txt
3. 设置环境变量并运行:
**Bash**
export CONFIG_FILE="./config/repos.yml"
python3 src/main.py
## 📝 许可证
本项目基于 **MIT** 许可证分发。
详见 `LICENSE` 文件。
CHAVATTE SECURITY
由 DevChavatte 开发
标签:Cilium, CVE漏洞检测, DevSecOps, Docker, GNU通用公共许可证, MITM代理, Node.js, NPM, PNPM, Sentinel Ops, WebSocket, Yarn, 上游代理, 云安全监控, 互联网扫描, 代码安全, 依赖分析, 可视化仪表盘, 安全防御评估, 开源组件安全, 漏洞枚举, 版权保护, 结构化查询, 自动化安全, 请求拦截, 逆向工具, 静态分析