terraform-provider-prefect
terraform-provider-prefect copied to clipboard
When importing `prefect_workspace_role`, the scopes do not get imported properly
I've defined my resource as follows:
resource "prefect_workspace_role" "jamie_test" {
name = "jamie-test"
description = "hi"
scopes = [
"manage_blocks"
]
}
I then subsequently ran:
terraform import prefect_workspace_role.jamie_test a94f185e-c416-4667-a60a-68109be63f53
prefect_workspace_role.jamie_test: Importing from ID "a94f185e-c416-4667-a60a-68109be63f53"...
prefect_workspace_role.jamie_test: Import prepared!
Prepared prefect_workspace_role for import
prefect_workspace_role.jamie_test: Refreshing state... [id=a94f185e-c416-4667-a60a-68109be63f53]
Import successful!
The resources that were imported are shown above. These resources are now in
your Terraform state and will henceforth be managed by Terraform.
but when I run a terraform plan without changing my defined resource, I receive this proposed change:
prefect_workspace_role.jamie_test: Refreshing state... [id=a94f185e-c416-4667-a60a-68109be63f53]
Terraform used the selected providers to generate the following execution plan. Resource actions are indicated with the following symbols:
~ update in-place
Terraform will perform the following actions:
# prefect_workspace_role.jamie_test will be updated in-place
~ resource "prefect_workspace_role" "jamie_test" {
~ account_id = "9a67b081-4f14-4035-b000-1f715f46231b" -> (known after apply)
~ created = "2023-11-07T20:06:48Z" -> (known after apply)
id = "a94f185e-c416-4667-a60a-68109be63f53"
name = "jamie-test"
+ scopes = [
+ "manage_blocks",
]
~ updated = "2023-11-07T20:15:45Z" -> (known after apply)
# (1 unchanged attribute hidden)
}
Plan: 0 to add, 1 to change, 0 to destroy.