You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I deleted a template outside of terraform because it was broken and I had issues with adding an additional parameter to it.
When I ran a terraform plan afterwards to restore the template, it failed with the following error:
╷
│ Error: Client Error
│
│ with coderd_template.templates["kubernetes"],
│ on templates.tf line 2, in resource "coderd_template" "templates":
│ 2: resource "coderd_template" "templates" {
│
│ Failed to get template: GET
│ https://REDACTED/api/v2/templates/REDACTED:
│ unexpected status code 404: Resource not found or you do not have access to
│ this resource
╵
I would have expected the provider to detect changes outside of terraform and be able to handle them
The text was updated successfully, but these errors were encountered:
I think it's reasonable for resources to mark themselves as deleted if fetching them fails with a 404 status code. Hashicorp would appear to agree - will fix!
The framework should be able to handle most/all other forms of state drift - this specific case just needs special handling because it can't differentiate not found errors.
I deleted a template outside of terraform because it was broken and I had issues with adding an additional parameter to it.
When I ran a terraform plan afterwards to restore the template, it failed with the following error:
╷
│ Error: Client Error
│
│ with coderd_template.templates["kubernetes"],
│ on templates.tf line 2, in resource "coderd_template" "templates":
│ 2: resource "coderd_template" "templates" {
│
│ Failed to get template: GET
│ https://REDACTED/api/v2/templates/REDACTED:
│ unexpected status code 404: Resource not found or you do not have access to
│ this resource
╵
I would have expected the provider to detect changes outside of terraform and be able to handle them
The text was updated successfully, but these errors were encountered: