diff --git a/changelogs/fragments/1038-ec2-insufficient-capacity.yml b/changelogs/fragments/1038-ec2-insufficient-capacity.yml new file mode 100644 index 00000000000..0058fe5cbb4 --- /dev/null +++ b/changelogs/fragments/1038-ec2-insufficient-capacity.yml @@ -0,0 +1,3 @@ +--- +minor_changes: + - ec2_instance - expanded the use of the automatic retries to ``InsuffienctInstanceCapacity`` (https://github.com/ansible-collections/amazon.aws/issues/1038). diff --git a/plugins/modules/ec2_instance.py b/plugins/modules/ec2_instance.py index 2125ab5a42a..367859fbf37 100644 --- a/plugins/modules/ec2_instance.py +++ b/plugins/modules/ec2_instance.py @@ -2069,6 +2069,7 @@ def main(): retry_decorator = AWSRetry.jittered_backoff( catch_extra_error_codes=[ 'IncorrectState', + 'InsuffienctInstanceCapacity', ] ) client = module.client('ec2', retry_decorator=retry_decorator)