This repository was archived by the owner on Jan 17, 2025. It is now read-only.
This repository was archived by the owner on Jan 17, 2025. It is now read-only.
drift after apply of redshift_schema.owner #138
Open
Description
I added this to our terraform project:
data "aws_redshift_cluster" "analytics" {
cluster_identifier = "analytics"
}
provider "redshift" {
host = data.aws_redshift_cluster.analytics.endpoint
username = "terraform"
database = "analytics"
temporary_credentials {
cluster_identifier = data.aws_redshift_cluster.analytics.cluster_identifier
auto_create_user = true
}
}
resource "redshift_schema" "spectrum" {
for_each = toset(["redacted"])
name = each.key
external_schema {
database_name = each.key
data_catalog_source {
iam_role_arns = [data.aws_iam_role.redshift.arn]
}
}
}
data "redshift_group" "analysts" {
name = "analysts"
}
resource "redshift_grant" "group" {
for_each = redshift_schema.spectrum
group = data.redshift_group.analysts.name
schema = each.key
object_type = "schema"
privileges = ["usage"]
}
if I run a plan right after apply, I expect no changes but instead get
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:
# redshift_schema.spectrum["redacted"] will be updated in-place
~ resource "redshift_schema" "spectrum" {
id = "11396018"
name = "redacted"
~ owner = "IAM:terraform" -> "iam:terraform"
# (1 unchanged attribute hidden)
# (1 unchanged block hidden)
}
Plan: 0 to add, 1 to change, 0 to destroy.
Metadata
Metadata
Assignees
Labels
No labels