Skip to content

Commit 8c20030

Browse files
committed
feat: upgrade to AL2023 (cleanup using coalesce + line fmt)
1 parent b734a58 commit 8c20030

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

data.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,4 +20,4 @@ data "aws_ami" "amazon_linux_2023" {
2020
name = "virtualization-type"
2121
values = ["hvm"]
2222
}
23-
}
23+
}

main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,7 @@ DOC
271271

272272
resource "aws_launch_template" "default" {
273273
name_prefix = module.this.id
274-
image_id = length(var.ami) > 0 ? var.ami : data.aws_ami.amazon_linux_2023.id
274+
image_id = coalesce(var.ami, data.aws_ami.amazon_linux_2023.id)
275275
instance_type = var.instance_type
276276
key_name = var.key_pair_name
277277
user_data = base64encode(var.user_data)

0 commit comments

Comments
 (0)