Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

provider/aws: ignore association not exist on EIP destroy [GH-2295] #2543

Merged
merged 1 commit into from
Jun 29, 2015

Conversation

mitchellh
Copy link
Contributor

Fixes #2295

This ignores if the association is gone for an EIP during the destruction phase. This can happen because an instance destroy automatically removes the association, and we have clear refresh-then-destroy phases in TF>

@phinze
Copy link
Contributor

phinze commented Jun 29, 2015

LGTM

mitchellh added a commit that referenced this pull request Jun 29, 2015
provider/aws: ignore association not exist on EIP destroy [GH-2295]
@mitchellh mitchellh merged commit 6860765 into master Jun 29, 2015
@mitchellh mitchellh deleted the b-elastic-ip-destroy branch June 29, 2015 17:35
@osterman
Copy link

I keep running into this error with terraform 0.8.8.

1 error(s) occurred:

* aws_eip_association.bastion (deposed #0): Error deleting Elastic IP association: InvalidAssociationID.NotFound: The association ID 'eipassoc-b9ec1b89' does not exist
	status code: 400, request id: 59643650-70f0-44f0-ad1d-68fdb3f9fe10

Here's the plan:

- aws_eip_association.bastion (deposed)

- aws_instance.bastion (deposed)

Here are the resources:

resource "aws_eip" "bastion" {
  vpc = true

  lifecycle {
    create_before_destroy = true
  }
}

resource "aws_eip_association" "bastion" {
  instance_id   = "${aws_instance.bastion.id}"
  allocation_id = "${aws_eip.bastion.id}"
}

@osterman
Copy link

The only way I've been able to get around it is by running:

bin/terraform-0.8.8/terraform state rm aws_eip_association.bastion

@ghost
Copy link

ghost commented Apr 15, 2020

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@ghost ghost locked and limited conversation to collaborators Apr 15, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Error tracking elastic IP addresses, and their associations to instances.
4 participants