feat: one-line install for agents and probes from one shared script (curl | bash, zsh, PowerShell) [CI]
ci/woodpecker/push/main-amd64-build Pipeline was successful
ci/woodpecker/push/main-amd64-build Pipeline was successful
This commit is contained in:
1 parent
5528753d45
commit
af2962fc58
29 files changed
+558
-124
No files matched your search
+6
-4
@@ -16,10 +16,12 @@
|
||||
|
||||
```text
|
||||
管理员 ── 创建加入令牌 {标签, max_uses, 过期时间, auto_approve} ──> 面板(Fleet.Server.Enrollment)
|
||||
<── 安装命令:
|
||||
curl -fsSL https://panel/install.sh | sh -s -- --join jt_xxx --name jp-1
|
||||
<── 一行安装命令(Agent 和 Probe 共用,没有占位符,节点名字默认取主机名):
|
||||
curl -fsSL 'https://panel/install?code=jt_xxx' | bash (macOS 用 zsh)
|
||||
irm 'https://panel/install.ps1?code=jt_xxx' | iex (Windows)
|
||||
|
||||
install.sh(只做安装,不包含任何远程控制功能;容器节点的做法见 deployment.md)
|
||||
面板按代码生成脚本(packaging/install/,嵌入 Backend):用 Docker 或 Podman 起容器,镜像入口用代码注册,身份和配置在命名卷里。
|
||||
下面是发布包里的 install.sh(二进制安装,不包含任何远程控制功能;容器节点的做法见 deployment.md):
|
||||
├─ 下载 moshiro-agent、fleet-enroll,并校验 SHA-256
|
||||
├─ 创建系统用户 moshiro(运行 Agent)
|
||||
├─ fleet-enroll --server https://panel --join jt_xxx --name jp-1 --identity-dir /etc/moshiro
|
||||
@@ -92,7 +94,7 @@ Probe 启动
|
||||
| GET/PATCH/DELETE | `/api/admin/probes`、`/probes/{id}` | Probe 的列表、改名、删除 |
|
||||
| POST | `/api/admin/probes/{id}/revoke` | 吊销(换密钥就是吊销之后重新注册,没有轮换) |
|
||||
| POST | `/api/admin/agents/{id}/probes/{probe_id}/disconnect` | 让 Agent 断开某个 Probe |
|
||||
| GET | `/install.sh`、`/install.ps1` | 安装脚本 |
|
||||
| GET | `/install?code=…`、`/install.ps1?code=…` | 一行安装脚本(凭一次性代码,Agent 和 Probe 共用) |
|
||||
|
||||
|
||||
## Agent 的本地配置:主机状态上报
|
||||
|
||||
Reference in new issue
Block a user