-
Notifications
You must be signed in to change notification settings - Fork 9.6k
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
Tags get lost as part of an instance destroy & recreate #464
Comments
I haven't experienced this - you are referring to ec2 tags, correct? Are you terminating the instances via Terraform or via the AWS console? |
I'm referring to EC2 tags, yep. Terraform terminated my instances for me as a result of #463 and recreated them in one fell swoop. As such I then had two copies of each instance showing in the AWS console - all of my "Terminated" ones had the Name tags, all the new ones that had been re-provisioned were missing tags. |
Just to clarify how I re-tagged the instances: Renamed the old tags to have "-deleted" as a suffix through the AWS console |
Reproduced this with a basic |
Fixed! |
As a result of my instances being dropped & recreated, I've just noticed that none of them had their tags re-applied when recreated. I think this is probably due to them no longer being unique as the old hosts still have the tags but are in a "Terminated" state.
Maybe on instance destruction the tags should either be deleted or have a timestamp appended to them so that they are available to reuse? I've worked around the current situation by renaming the old tags manually & re-applying through terraform.
The text was updated successfully, but these errors were encountered: