CLI 目录 横向对比 FCRS-1.0 标准 关于我们 /llms.txt

Nacos CLI

$ nacos 官方出品 中风险
Nacos (Alibaba) · 云原生与基础设施 · Apache-2.0 · macos / linux / windows · 评测日期:

Nacos CLI(nacos / nacos-cli)是 nacos-group/nacos-cli 官方推出的 Go 命令行工具,用于查看与管理 Nacos 配置、命名空间、服务实例以及 AI 技能/Agent 规范;支持多连接 Profile(profile set)及 none、nacos、aliyun、sts-hiclaw 等多种认证模式,可通过 @nacos-group/cli 或安装脚本部署。

FCRS-1.0 综合评分
69 /100
可用但有局限
中置信度 (源码/文档)
零摩擦安装命令
npm install -g @nacos-group/cli
CLI vs MCP 选型建议 优先选 CLI

nacos 可直接使用本地保存的连接配置直连内网/VPC Nacos 集群,无需通过中间 MCP 服务器暴露注册中心凭证。

核心事实概览

命令名
$ nacos
FCRS-1.0 总分
69/100 (可用但有局限)
证据置信度
中置信度 (源码/文档)
CLI vs MCP 建议
优先选 CLI
评测日期

Agent 友好度体检单

— 原生 JSON 输出
— 字段裁剪
✓ 无头非交互
— 支持 Dry-Run
— 只读模式开关
— 支持 NO_COLOR
✓ 自省/Schema 发现
— 官方 SKILL.md

当前为静态评估(本机尚未安装或尚未运行探针)。可在本地运行 npm run data:probe 并提交 data/probes/ 升级为实测证据。

FCRS-1.0 六维评分拆解

Agent 友好度 16 / 25

提供无交互的 profile set 与子命令参数,但仍处于早期演进阶段,各子命令尚缺乏统一的 --json 与 --dry-run 支持。

  • Non-interactive profile set subcommands
  • Early-stage CLI lacking universal --json output across subcommands
安全与权限边界 17 / 25

支持命名连接 Profile 以及 nacos/aliyun/sts-hiclaw 认证模式进行访问隔离,但覆盖写入配置前缺少内置预演功能。

  • Named connection profiles and nacos / aliyun / sts-hiclaw auth modes
安装与运行摩擦 12 / 15

跨平台 Go 二进制,可通过 npm install -g @nacos-group/cli、官方安装脚本或 go build 获取。

  • Available via @nacos-group/cli on npm and Nacos installer scripts
能力覆盖与边际价值 11 / 15

免去手写 Nacos HTTP API curl 脚本,便捷管理配置、命名空间与 AI 规范。

  • Wraps Nacos config, namespace, and AI skill/spec management
维护与来源背书 7 / 10

由 Nacos 官方组织在 nacos-group/nacos-cli 仓库维护,目前仍属新兴项目(44 星标)。

  • Official nacos-group/nacos-cli repo (44 stars)
文档与可验证性 6 / 10

在 Nacos 官方文档与 --help 中有基础说明,边界参数与示例相对精简。

  • Nacos CLI reference page on nacos.io

安全边界、鉴权与放权指南

鉴权方式
无需鉴权 本地配置文件 服务账号密钥
凭证存储位置

将服务器地址、端口及认证模式(nacos、aliyun、sts-hiclaw)保存在本地 ~/.nacos/ 目录的 Profile 配置中。

潜在副作用
只读查询 本地写入 远端写入 破坏性删除
费用与配额提示

开源免费(Apache-2.0);可对接自建 Nacos 或阿里云 MSE Nacos。

可复制到 CLAUDE.md / AGENTS.md 的安全护栏
# Nacos CLI Agent Rules
- Always verify active profile host, port, and namespace before reading or publishing configs.
- Target staging namespaces explicitly before modifying production Nacos configuration keys.
- Require user approval before deleting configs or deregistering service instances.

Agent 高频安全命令配方

只读查询(安全推荐)

查看 CLI 帮助与可用子命令
nacos-cli --help

列出可用的配置、服务与 Profile 管理子命令。

受控写入与预演

配置本地 Nacos 连接 Profile
nacos-cli profile set default host=127.0.0.1

在执行命令前将 default Profile 的主机固定为本地 Nacos 实例。

核心优势

  • + 支持 none、nacos、aliyun、sts-hiclaw 等多种认证后端及命名 Profile。
  • + 可通过 npm install -g @nacos-group/cli 或官方安装脚本快速安装。
  • + 替代手写繁琐的 Nacos OpenAPI curl 脚本。

注意事项与踩坑点

  • ! 项目处于早期阶段(44 星标),结构化 --json 输出标准化程度与示例文档尚待完善。
  • ! 不同安装方式下可执行文件名可能为 nacos 或 nacos-cli。

已验证兼容的 Agent 宿主

Claude Code Codex CLI Gemini CLI

同分类相关 CLI: 云原生与基础设施

进入分类页 →
$ nats-server

nats-server — 云原生与基础设施命令行工具(High-Performance server for NATS.io, the cloud and edge native messaging system)

nelm 69/100
$ nelm

nelm — 云原生与基础设施命令行工具(Nelm is a Helm 3 alternative. It is a Kubernetes deployment tool that manages Helm Charts )

$ mongodb-atlas-cli

mongodb-atlas-cli — 云原生与基础设施命令行工具(MongoDB Atlas CLI and MongoDB CLI enable you to manage your MongoDB in the Cloud)

netfetch 69/100
$ netfetch

netfetch — 云原生与基础设施命令行工具(Kubernetes tool for scanning clusters for network policies and identifying unprotected wor)

$ opa

CNCF 策略引擎 CLI,支持以 JSON 格式评估、测试与格式化 Rego 策略。

cfn-lint 94/100
$ cfn-lint

AWS 官方 CloudFormation 静态检查工具,提供确定性的 `-f json` 与 SARIF 输出。