Skip to content

Creating aws_instance when there is no volume capacity should fail faster #42890

Open
@SimonEismann

Description

@SimonEismann

Terraform and AWS Provider Version

Terraform: 1.5.0
AWS provider: 5.2.0

Affected Resource(s) or Data Source(s)

  • aws_instance

Expected Behavior

Upon encountering an InsufficientVolumeCapacityError, terraform should fail or alternatively retry until the default timeout of 10 minutes is hit.

Actual Behavior

Terraform attempts to retry provisioning the instance for 1 hour until it finally fails.

This behavior is consistent with what has previously been reported for InsufficientInstanceCapacity:

For InsufficientInstanceCapacity this behavior was fixed in #21293.

Sample Terraform Configuration

Any terraform config that deploys an EC2 instance with an EBS disk attached.

Steps to Reproduce

This is challenging to reproduce given that it requires AWS to report an InsufficientVolumeCapacityError. The best way to reproduce this is likely to mock the calls to AWS and make them report an InsufficientVolumeCapacityError.

Would you like to implement a fix?

No

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugAddresses a defect in current functionality.needs-triageWaiting for first response or review from a maintainer.service/ec2Issues and PRs that pertain to the ec2 service.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions