etcd

GitHub

提供 etcd 键值存储的读写能力,支持 get/put/del 及 lease、member 等管理操作。通过简化命令语法和严格参数校验,实现安全可靠的配置与状态管理。

internal/ai/skills/etcd/SKILL.md opskat/opskat

Trigger Scenarios

需要读取或修改 etcd 中的配置项 查询 etcd 集群成员或端点健康状态 管理 etcd 租约(lease)

Install

npx skills add opskat/opskat --skill etcd -g -y
More Options

Non-standard path

npx skills add https://github.com/opskat/opskat/tree/main/internal/ai/skills/etcd -g -y

Use without installing

npx skills use opskat/opskat@etcd

指定 Agent (Claude Code)

npx skills add opskat/opskat --skill etcd -a claude-code -g -y

安装 repo 全部 skill

npx skills add opskat/opskat --all -g -y

预览 repo 内 skill

npx skills add opskat/opskat --list

SKILL.md

Frontmatter
{
    "name": "etcd",
    "description": "Read and write etcd keys via exec, using an etcdctl-like command syntax."
}

etcd assets

Command syntax

<op> [key] [value] [--flags] — a subset of etcdctl.

  • get /app/config
  • get /app/ --prefix
  • get '' --prefix (whole keyspace — get --prefix with no key errors)
  • get /app/config --limit=10 --revision=42
  • put /app/config 'hello world'
  • put /app/config '{"debug": true}' --lease=694d5c0f
  • del /app/ --prefix
  • lease grant --ttl=3600
  • lease revoke --lease=694d5c0f
  • lease list
  • member list
  • endpoint status
  • endpoint health

Notes

  • get/del/put always require a key positional — even to read the whole keyspace, pass an explicit empty key: get '' --prefix. A bare get --prefix errors because there is no key argument.
  • Quote any value containing spaces or JSON: put /k '{"a": 1}'. An unquoted multi-word value is rejoined with spaces (put /k hello world sets the value to hello world), so quote it whenever the intent should be unambiguous.
  • --lease is hexadecimal, matching etcdctl.
  • Two-word ops (lease grant, member list, endpoint status) are written with a space, exactly as shown.
  • Unknown flags are rejected rather than ignored.
  • A key/value token starting with -- is parsed as a flag, not as data: if it matches a known flag name it is consumed as that flag instead (put /k --limit=5 fails with "requires key and value" because --limit=5 becomes the --limit flag, not the value); if it doesn't, the whole command is rejected ("unknown flag"). A single leading - is ordinary data and is not affected (get -foo reads key -foo).
  • The command line is shell-tokenized but not shell-executed: $, |, >, & and similar shell metacharacters produce an error rather than expanding or redirecting. put /k "$HOME" fails; wrap values containing such characters in single quotes so they are taken literally.
  • This is a narrower subset of etcdctl than it looks: range syntax (get /a /b meaning "everything from /a to /b") is not supported. Extra positionals are silently dropped for get/del (get /a /b reads only /a) and joined into the value for put. Use --prefix for range-like reads.
  • The scope parameter is not used by etcd assets.

Asset config (for put_asset)

field type required notes
endpoints string yes Comma/semicolon/newline separated host:port list, no scheme prefix — each entry must parse as host:port, so http:///https:// is rejected with etcd endpoint必须为host:port格式: e.g. "10.0.1.5:2379,10.0.1.6:2379"
username string no etcd account name
password string no Write-only. Encrypted in the asset; does not create a credential
credential_id number no Existing managed password credential ID
tls bool no true to enable TLS
tls_insecure bool no true to skip TLS certificate verification
tls_server_name string no TLS SNI / server name override
tls_ca_file string no Path to a CA certificate file
tls_cert_file string no Path to a client certificate file (mTLS)
tls_key_file string no Path to a client key file (mTLS)
dial_timeout_seconds number no Connection dial timeout override, in seconds
command_timeout_seconds number no Per-command timeout override, in seconds
ssh_asset_id number no SSH asset to tunnel through; 0 detaches

password and credential_id are mutually exclusive. Plaintext is never returned, is encrypted in the asset, and never creates a managed credential.

Version History

  • b159e91 Current 2026-08-19 20:20
  • d6c7a6e 2026-08-16 07:28

    修正etcd endpoint报错文案及bool字段类型描述错误

  • aeb4bc3 2026-07-24 16:28

Same Skill Collection

internal/ai/skills/database/SKILL.md
internal/ai/skills/k8s/SKILL.md
internal/ai/skills/kafka/SKILL.md
internal/ai/skills/local/SKILL.md
internal/ai/skills/mongodb/SKILL.md
internal/ai/skills/oss/SKILL.md
internal/ai/skills/rdp/SKILL.md
internal/ai/skills/redis/SKILL.md
internal/ai/skills/serial/SKILL.md
internal/ai/skills/ssh/SKILL.md
internal/ai/skills/vnc/SKILL.md
plugin/opsctl/skills/opsctl/SKILL.md

Metadata

Files
0
Version
b159e91
Hash
fe87c434
Indexed
2026-07-24 16:28

- 위키
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-08-21 07:03
浙ICP备14020137号-1 $방문자$