AWS CLI filter OR logic

I am trying to get a list of servers using AWS CLI tools. I have 2 server groups, I will have the "mind" string in the Name tag, the other group will have the "intelligence" string in the Name tag.

I can filter the output of DescribeInstances using wildcards, but can I return instances that contain mind or intelligence? in the name?

I currently need to execute a command that replaces the parameter value twice.

+3


source to share


1 answer


You can provide multiple values ​​for the tag. I think that something like this will work for you:



aws ec2 describe-instances --filters Name=tag:Name,Values=mind,intelligence

      

+6


source







All Articles