Fix for #20473 - If there is no instance in the ASG, we initialize an empty array for properties['instances']
(#20475)
This commit is contained in:
parent
86db15b105
commit
0d2d25b515
1 changed files with 2 additions and 0 deletions
|
@ -306,6 +306,8 @@ def get_properties(autoscaling_group):
|
||||||
properties['terminating_instances'] += 1
|
properties['terminating_instances'] += 1
|
||||||
if i.lifecycle_state == 'Pending':
|
if i.lifecycle_state == 'Pending':
|
||||||
properties['pending_instances'] += 1
|
properties['pending_instances'] += 1
|
||||||
|
else:
|
||||||
|
properties['instances'] = []
|
||||||
properties['instance_facts'] = instance_facts
|
properties['instance_facts'] = instance_facts
|
||||||
properties['load_balancers'] = autoscaling_group.load_balancers
|
properties['load_balancers'] = autoscaling_group.load_balancers
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue