1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Only inventory "running" EC2 instances. "stopped" is also a valid state and these should not be inventoried.

This commit is contained in:
Tim Gerla 2013-01-30 11:01:25 -08:00
parent 0243b7be7c
commit 168fcb0a4a

View file

@ -274,7 +274,7 @@ class Ec2Inventory(object):
addressable '''
# Only want running instances
if instance.state == 'terminated':
if instance.state != 'running':
return
# Select the best destination address