@app-vitals/agent-admin

中文文档
1.2.5发布于 2026/11/07MITES Module构建来源已验证近 30 天下载 1.1万

Shipwright admin service — CRUD API + UI for agents, env vars, cron jobs, tokens, tools, and plugins

原始使用文档
文档目录5 节
  1. Running Locally
  2. Environment Variables
  3. Database
  4. Building the Docker Image
  5. Deployment

Shipwright Admin Service

The admin service provides a web UI and CRUD API for managing Shipwright agents — env vars, cron jobs, tokens, tools, and plugins. It also exposes the runtime API used by deployed agents to fetch their configuration.

The HTTP server is implemented in admin/src/main.ts, which composes the admin UI, admin CRUD API, and agent runtime API into a single Hono app running on port 3000.

Running Locally

# From repo root — install all workspace deps
bun install

# Export required env vars (see Environment Variables table below)
export DATABASE_URL_SHIPWRIGHT_ADMIN=postgresql://...
export SHIPWRIGHT_SESSION_SECRET=...
# ... (remaining vars)

# Run the admin server
bun run admin/src/main.ts

The service listens on http://localhost:3000 by default. Visit /admin for the UI.

Environment Variables

VariableRequiredDescription
DATABASE_URL_SHIPWRIGHT_ADMINYesPostgreSQL connection string for the admin Prisma schema
SHIPWRIGHT_SESSION_SECRETYesJWT cookie secret for admin UI sessions
GOOGLE_CLIENT_IDYesGoogle OAuth 2.0 client ID for admin UI login
GOOGLE_CLIENT_SECRETYesGoogle OAuth 2.0 client secret
SHIPWRIGHT_ADMIN_ALLOWED_EMAILSYesComma-separated list of emails permitted to log in
SHIPWRIGHT_ADMIN_APP_BASE_URLYesPublic base URL used for OAuth redirect (defaults to http://localhost:3000)
SHIPWRIGHT_ADMIN_API_KEYSNoComma-separated name:token:scope tuples for bearer token auth. Scope is *, an agent id, platform.read or platform.ops (no colons in scopes) — see docs/agent-api.md
SHIPWRIGHT_ENCRYPTION_KEYRecommended64-char hex key for AES-256-GCM encryption of stored secrets
PORTNoHTTP server port (defaults to 3000)

Database

The admin service uses its own PostgreSQL database. Run migrations before starting:

export DATABASE_URL_SHIPWRIGHT_ADMIN=postgres://...
cd admin && bunx prisma migrate deploy --schema=prisma/schema

Building the Docker Image

Build from the repo root (the Dockerfile uses the full monorepo context):

docker build -f admin/Dockerfile -t shipwright-admin .

Run the image:

docker run \
  -e DATABASE_URL_SHIPWRIGHT_ADMIN=postgres://... \
  -e SHIPWRIGHT_SESSION_SECRET=... \
  -e GOOGLE_CLIENT_ID=... \
  -e GOOGLE_CLIENT_SECRET=... \
  -e [email protected] \
  -e SHIPWRIGHT_ADMIN_APP_BASE_URL=https://admin.example.com \
  -p 3000:3000 \
  shipwright-admin

Deployment

A GKE Deployment + Service manifest is provided at admin/deploy/deployment.yaml.

It expects a Kubernetes Secret named shipwright-admin-secret containing all required env vars. See the comments at the top of the manifest for setup instructions.

版本与发布记录

@app-vitals/agent-admin 共发布 37 个版本,首次发布于 2026/10/24;过去 12 个月发布了 37 个版本。最新版本附带 npm provenance 构建来源证明,可追溯到公开的 CI 构建记录。

版本发布日期距今
1.2.5latest2026/11/071 天前
1.2.42026/11/061 天前
1.2.32026/11/043 天前
1.2.22026/11/043 天前
1.2.12026/11/043 天前
1.2.02026/11/044 天前

关于 @app-vitals/agent-admin 的常见问题

@app-vitals/agent-admin 是什么?

Shipwright admin service — CRUD API + UI for agents, env vars, cron jobs, tokens, tools, and plugins

如何安装 @app-vitals/agent-admin?

在项目目录运行 npm install @app-vitals/agent-admin,或使用 pnpm add / yarn add / bun add。

@app-vitals/agent-admin 支持 TypeScript 吗?

该包的 package.json 没有声明类型入口。需要类型提示时,可以在 npm 上查找社区维护的 @types/app-vitals__agent-admin 是否存在。

@app-vitals/agent-admin 支持 ESM 还是 CommonJS?

以 ES Module 形式发布,推荐使用 import 引入。在 CommonJS 项目中,Node.js 20.19+ / 22.12+ 可以直接 require() 不含顶层 await 的 ES Module,更早的版本需要改用动态 import()。

@app-vitals/agent-admin 可以商用吗?

@app-vitals/agent-admin 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@app-vitals/agent-admin 的下载量有多少?

根据 npm 官方下载统计,@app-vitals/agent-admin 在 2026/10/07 – 2026/11/05 这 30 天内被下载 11,317 次,日均约 377 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@app-vitals/agent-admin 还在维护吗?

最新版本 1.2.5 发布于 2026/11/07(1 天前);至今共发布 37 个版本,其中过去 12 个月发布了 37 个;首次发布于 2026/10/24。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。