跳到主要内容

ecs prefix-list

管理前缀列表

运行 ecctl ecs prefix-list <action> -h 查看用法,或 ecctl schema ecs.prefix-list.<action> --full 获取该命令完整的结构化规格——每个参数与行为,便于 Agent 读取和填参。

create

ecctl ecs prefix-list create [flags]

创建前缀列表

  • 类型:mutation · 风险:medium
  • 同步:等待 matched(waiter entries_visible,超时 300s);用 --no-wait 跳过等待。
  • 通过 ClientToken 幂等。
API调用时机用途
CreatePrefixList每次执行命令时执行资源操作。
DescribePrefixListAttributes未指定 --no-wait 且指定 --entry轮询等待资源达到目标状态。(重复调用)
DescribePrefixListAttributes未指定 --no-wait读取资源视图。
参数类型必填说明
--address-familystringIP 地址族
--max-entriesinteger最大条目数量
--namestring前缀列表名称
--regionstringAlibaba Cloud region
--descriptionstring前缀列表描述
--entryobject创建时的前缀列表条目
--resource-groupstring资源组 ID
--tagkey_value标签赋值 key=value

update

ecctl ecs prefix-list update <id> [flags]

更新前缀列表

  • 类型:mutation · 风险:medium
  • 同步:等待 matched(waiter entries_visible,超时 300s);用 --no-wait 跳过等待。
API调用时机用途
ModifyPrefixList每次执行命令时执行资源操作。
DescribePrefixListAttributes未指定 --no-wait--entry 中包含以 + 为前缀的值时轮询等待资源达到目标状态。(重复调用)
DescribePrefixListAttributes未指定 --no-wait--entry 中包含以 - 为前缀的值时轮询等待资源达到目标状态。(重复调用)
DescribePrefixListAttributes未指定 --no-wait读取资源视图。
参数类型必填说明
--regionstringAlibaba Cloud region
--descriptionstring前缀列表描述
--entrystring条目变更,使用 + 前缀新增或 - 前缀删除
--namestring前缀列表名称

delete

ecctl ecs prefix-list delete <id> [flags]

删除前缀列表

  • 类型:mutation · 风险:high
API调用时机用途
DeletePrefixList每次执行命令时执行资源操作。
参数类型必填说明
--regionstringAlibaba Cloud region

get

ecctl ecs prefix-list get <id> [flags]

获取前缀列表

  • 类型:read · 风险:low
API调用时机用途
DescribePrefixListAttributes每次执行命令时读取资源视图。
DescribePrefixListAssociations指定 --with-associations读取资源视图。
参数类型必填说明
--regionstringAlibaba Cloud region
--fieldsstring要包含的资源字段,使用逗号分隔
--with-associationsboolean附带关联资源

list

ecctl ecs prefix-list list [<ids>...] [flags]

列出前缀列表

  • 类型:read · 风险:low
API调用时机用途
DescribePrefixLists每次执行命令时读取资源视图。
参数类型必填说明
--regionstringAlibaba Cloud region
--fieldsstring要包含的资源字段,使用逗号分隔
--filterkey_value过滤表达式 key=value
--limitinteger最多返回资源数量(默认:100
--next-tokenstring下一页查询 token