From a6890383061118090cd218b9dd13cf5b0a8f189d Mon Sep 17 00:00:00 2001 From: Daniel Mason Date: Sat, 22 Apr 2023 13:26:52 +1200 Subject: [PATCH] Readd tags --- ec2.tf | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/ec2.tf b/ec2.tf index a5e6e28..804c1b0 100644 --- a/ec2.tf +++ b/ec2.tf @@ -9,6 +9,14 @@ resource "aws_instance" "instance" { subnet_id = element(aws_subnet.subnet.*.id, 1) key_name = var.ssh_key vpc_security_group_ids = [aws_security_group.sg.id] + + tags = { Name = "status.fediservices.nz" } + + lifecycle { + ignore_changes = [ + tags, + ] + } } # Elastic IP @@ -16,7 +24,7 @@ resource "aws_eip" "eip" { instance = aws_instance.instance.id vpc = true - tags { Name = "status.fediservices.nz" } + tags = { Name = "status.fediservices.nz" } } # EBS Vol for persistance