项目实践
pod-upgrade-trigger
Small Rust HTTP service that validates GitHub package events, enforces rate limits, refreshes Podman images, and restarts systemd units; ships a Web UI (embedded bundle) and CLI subcommands for ops tasks.
目录
技术栈
运行与交付
- CI 工作流
- ci.yml
- 能力标记
- cargo_toml
- dockerfile
- github_actions
配置与质量
- 配置文件
- .dockerignore
- .env
- .gitignore
- Cargo.toml
- lefthook.yml
其他信息
- Cargo
- 开发依赖
- tempfile
- Deps main
- base64
- hex
- hmac
- libc
JSON
{
"cargo": {
"deps_dev": [
"tempfile"
],
"deps_main": [
"base64",
"hex",
"hmac",
"libc",
"nanoid",
"regex",
"reqwest",
"rust-embed",
"semver",
"serde",
"serde_json",
"sha2",
"sqlx",
"subtle",
"tokio",
"url"
]
},
"ci_workflows": [
"ci.yml"
],
"configs_root": [
".dockerignore",
".env",
".gitignore",
"Cargo.toml",
"lefthook.yml"
],
"markers_present": [
"cargo_toml",
"dockerfile",
"github_actions"
]
}Basics
Small Rust HTTP service that validates GitHub package events, enforces rate limits, refreshes Podman images, and restarts systemd units; ships a Web UI (embedded bundle) and CLI subcommands for ops tasks. Evidence: README.md, Cargo.toml, systemd/.
Architecture
- Single Rust binary crate with multiple subcommands (daemon + maintenance CLI). Evidence:
README.md,src/,bin/. - UI:
web/buildsweb/dist, which is embedded into the release binary (build.rs checks for it). Evidence:web/,build.rs.
Conventions
- Uses Lefthook for git hooks and scripted formatting. Evidence:
lefthook.yml,scripts/format_staged.sh. - Provides unit files and deployment notes for systemd-based installs. Evidence:
systemd/,README.md.
Taste notes
The build rule “release must embed the UI bundle” is a great guardrail for deployability — it avoids runtime surprises on minimal servers.