mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
* ROLLBACK_COMPLETE is a failure state Fixes #24578 * Adding AWS documentation on Stack status * Fixed comment
This commit is contained in:
parent
b230b03045
commit
3eb8142a41
1 changed files with 4 additions and 2 deletions
|
@ -343,7 +343,9 @@ def stack_operation(cfn, stack_name, operation):
|
||||||
else:
|
else:
|
||||||
ret.update({'changed': False, 'failed': True, 'output' : 'Stack not found.'})
|
ret.update({'changed': False, 'failed': True, 'output' : 'Stack not found.'})
|
||||||
return ret
|
return ret
|
||||||
elif stack['StackStatus'].endswith('_ROLLBACK_COMPLETE'):
|
# it covers ROLLBACK_COMPLETE and UPDATE_ROLLBACK_COMPLETE
|
||||||
|
# Possible states: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-describing-stacks.html#w1ab2c15c17c21c13
|
||||||
|
elif stack['StackStatus'].endswith('ROLLBACK_COMPLETE'):
|
||||||
ret.update({'changed': True, 'failed': True, 'output': 'Problem with %s. Rollback complete' % operation})
|
ret.update({'changed': True, 'failed': True, 'output': 'Problem with %s. Rollback complete' % operation})
|
||||||
return ret
|
return ret
|
||||||
# note the ordering of ROLLBACK_COMPLETE and COMPLETE, because otherwise COMPLETE will match both cases.
|
# note the ordering of ROLLBACK_COMPLETE and COMPLETE, because otherwise COMPLETE will match both cases.
|
||||||
|
|
Loading…
Reference in a new issue