Serverless Devs
$ s 基金会 高风险Serverless Devs(s)是一款 Apache-2.0 开源的多云 Serverless 工具链(1.8k+ 星标),支持阿里云函数计算(FC)、AWS Lambda、腾讯云 SCF 与华为云 FunctionGraph;基于 s.yaml 模板提供 s info、s deploy -y 与 s config 多账号别名管理。
npm install -g @serverless-devs/s s 负责代码打包、解析 s.yaml 组件插件与云端栈部署,这类重本地构建的工作流不适合通过无状态 MCP 调用完成。
核心事实概览
- 命令名
- $ s
- FCRS-1.0 总分
- 77/100 (良好 (Good))
- 证据置信度
- 中置信度 (源码/文档)
- CLI vs MCP 建议
- 优先选 CLI
- 评测日期
Agent 友好度体检单
当前为静态评估(本机尚未安装或尚未运行探针)。可在本地运行 npm run data:probe 并提交 data/probes/ 升级为实测证据。
FCRS-1.0 六维评分拆解
支持 -y(--assume-yes)、-t 模板指定与 -a 凭证别名参数便于自动化执行,但输出以人类可读日志和 YAML 为主。
- Non-interactive flags
-y,-t, and-aacross lifecycle commands - Output is primarily human-formatted logs and YAML rather than strict
--json
通过 -a <alias> 隔离不同账号密钥并提供只读 s info,但缺少全局 --dry-run 变更计划命令。
- Explicit
-a <alias>credential isolation in~/.s/access.yaml
跨平台 TypeScript CLI,可通过 npm install -g @serverless-devs/s 或 npx @serverless-devs/s 快速使用。
- Distributed on npm (
@serverless-devs/s) and GitHub releases
统一管理阿里云 FC、AWS 与腾讯云 SCF 的构建、本地调试、信息查询与部署。
- Component ecosystem covering major APAC and global FaaS providers
由开源社区/基金会托管的 Serverless-Devs/Serverless-Devs 仓库(1.8k+ 星标,Apache-2.0)维护。
Serverless-Devs/Serverless-Devsunder Apache-2.0 (1.8k+ stars)
在 serverless-devs.com 提供完整的 s.yaml 规范与组件市场文档。
- Comprehensive
s.yamlspec and CLI docs at docs.serverless-devs.com
安全边界、鉴权与放权指南
按别名将各云厂商密钥保存在 ~/.s/access.yaml,可通过 s config add -a <alias> 与 s config get 管理。
CLI 本身开源免费(Apache-2.0);部署后的 FaaS 函数与网关资源按对应云厂商计费。
# Serverless Devs (s) Agent Rules - Always pass `-t <template.yaml>` and `-a <access-alias>` explicitly so deployments never hit the wrong account. - Run `s info` before `s deploy -y` to verify existing cloud state. - Require user approval before running `s remove` or deploying production templates.
Agent 高频安全命令配方
只读查询(安全推荐)
s info -t s.yaml
针对当前 s.yaml 查询线上端点与运行状态,不修改云端资源。
s config get
展示保存在 ~/.s/access.yaml 中的多云凭证别名列表。
受控写入与预演
s deploy -t s-staging.yaml -a staging -y
使用指定 staging 凭证别名与 -y 自动确认参数部署 s-staging.yaml。
核心优势
- + 清晰的多云
s.yaml工作流,支持-a <alias>与-t <template>环境隔离。 - + 支持
-y非交互式确认,适合 CI/CD 与 Agent 自动化发布。 - + 可通过
npm install -g @serverless-devs/s一键安装。
注意事项与踩坑点
- ! 单字母命令
s在部分开发环境中容易与用户自定义 Shell 别名冲突。 - ! 缺少全局
--dry-run差异预览,各组件间也未统一--json输出格式。
已验证兼容的 Agent 宿主
Follow 家族生态联动
同分类相关 CLI: 云原生与基础设施
进入分类页 →Akamai 模块化官方 CLI,通过 `akamai install` 扩展管理 Edge DNS、Property Manager、EdgeWorkers 与缓存刷新。