diff --git a/main.tf b/main.tf index 244489b..749bb36 100644 --- a/main.tf +++ b/main.tf @@ -250,6 +250,10 @@ data "aws_iam_policy_document" "this" { resource "random_id" "this" { count = var.create && var.create_configuration ? 1 : 0 + keepers = { + kafka_version = var.kafka_version + } + byte_length = 8 } @@ -258,7 +262,7 @@ resource "aws_msk_configuration" "this" { name = format("%s-%s", coalesce(var.configuration_name, var.name), random_id.this[0].dec) description = var.configuration_description - kafka_versions = [var.kafka_version] + kafka_versions = [random_id.this[0].keepers.kafka_version] server_properties = join("\n", [for k, v in var.configuration_server_properties : format("%s = %s", k, v)]) lifecycle {