Commit 4d240a37 by John Jarvis

only return running instances

parent 48d4f54d
......@@ -128,6 +128,7 @@ def main():
for res in ec2.get_all_instances(filters={'tag:' + tag: value
for tag, value in tags.iteritems()}):
for inst in res.instances:
if inst.state == "running":
instances.append({k: v for k, v in inst.__dict__.iteritems()
if isinstance(v, (basestring))})
instance_ids.append(inst.id)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment