-
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
Deleted MX record fails refresh in DO #279
Labels
Comments
This is just a bug in Terraform. I've tagged it as such. Can you give us the error logs? It'd help us. State files are getting an overhaul in 0.3 which should also help with this, but we'll keep that as a separate issue. |
mitchellh
changed the title
Provide way to manually clean up state
Deleted MX record fails refresh in DO
Sep 9, 2014
mitchellh
added a commit
that referenced
this issue
Sep 9, 2014
Fixed |
How do I obtain an error log? Also, since this issue is closed, how Or was it resolved? Thanks. |
I resolved it! |
ghost
locked and limited conversation to collaborators
May 5, 2020
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Was having some issues with the Digital Ocean provider, so I manually deleted an MX record thinking Terraform would either recreate it or prune the state file. Bad idea, apparently. Now all Terraform actions fail because there is an error retrieving the record for the deleted API element.
Lesson learned, but it would be nice to have some mechanism manual or automatic for cleaning up state. Maybe if the API call fails with a 404, the Digital Ocean provider specifically or providers in general can mark the resource as missing and recreate it on the next run if possible?
And, more generally, it'd be nice to be able to dump and restore state files. Ideally Terraform does all necessary edits, but it's bound to make mistakes at this early phase and it'd be nice if I can clean those up.
Any tips on how I can get this digitalocean_record out of my tfstate in the meantime?
The text was updated successfully, but these errors were encountered: