【发布时间】:2017-04-08 02:50:58
【问题描述】:
我正在尝试编写一个脚本,以根据某种配置文件自动设置所需的 AutoScalingGroups 计数,例如,SHUTDOWN 配置文件应将所有内容设置为零。
我们在单个帐户本身下有很多应用程序。因此,当在命令下运行时,它会提供所有资源。
aws ecs list-clusters
有没有办法通过标签或任何其他方式过滤这些?显然 --filter 不是 aws ecs 或 aws autoscaling 命令的有效选项。
我现在正在使用 grep 命令。
aws ecs list-clusters | grep string1 | grep string2
【问题讨论】:
标签: amazon-web-services aws-cli