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

providers/aws: Retry deleting IAM Server Cert on dependency violation #3898

Merged
merged 2 commits into from
Nov 20, 2015

Conversation

catsby
Copy link
Contributor

@catsby catsby commented Nov 12, 2015

This PR does some things. I would normally separate them, but the two issues it resolves (Fixes #3412 and Fixes #3275, Fixes #3301) ended up being kind of coupled so they get fixed in one swoop.

  • retry deleting a server cert if it throws an error about being in use with an ELB (that we likely just deleted)
  • retry creating the ELB if it fails regarding an IAM cert that doesn't exist (that we likely just created)
  • includes test for ELB+IAM SSL cert bug dependency violation

This will retry deleting a server cert
if it throws an error about being in use with an ELB (that we've likely just
  deleted)

Includes test for ELB+IAM SSL cert bug dependency violation
@phinze
Copy link
Contributor

phinze commented Nov 18, 2015

LGTM

catsby added a commit that referenced this pull request Nov 20, 2015
providers/aws: Retry deleting IAM Server Cert on dependency violation
@catsby catsby merged commit cc70d25 into master Nov 20, 2015
@catsby catsby deleted the b-aws-elb-iam-cert-delete branch November 20, 2015 20:50
@johnhamelink
Copy link

@catsby has this made it into a release yet?

@catsby
Copy link
Contributor Author

catsby commented Dec 18, 2015

@johnhamelink yes, it was released in v0.6.7. Are you hitting something similar?

@aldarund
Copy link

@catsby im hitting similar. I want to change cert for ELB but fail with error.

  • aws_iam_server_certificate.rent_cert: [WARN] Conflict deleting server certificate: Certificate: ASCAIN22VALXE7QYJO6OY is currently in use by arn:aws:elasticloadbalancing:us-east-1:133662108267:loadbalancer/rentapp-service-elb. Please remove it first before deleting it from IAM., retrying
    Isnt this PR supposed to fix this?

@aldarund
Copy link

@catsby even more. terraform when i first get this error created a new launch conf and didnt deleted old one, so it ended up being two ec2 launch conf ( i use create_before_destroy + name generate like describedc in docs)

@catsby
Copy link
Contributor Author

catsby commented Jan 15, 2016

The refresh logic here is for when the cert isn't found during the ELB creation, the error you post is regarding the cert itself.

Looks like aws_iam_server_certificate needs to have an auto generated name option for use with create_before_destroy

@catsby
Copy link
Contributor Author

catsby commented Jan 15, 2016

I opened #4689 for the name generation

@ghost
Copy link

ghost commented Apr 28, 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 28, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
4 participants