From 5b5780ac7fd8b21db8b5fed3c5a5dd6b01c2a75e Mon Sep 17 00:00:00 2001 From: Eric Date: Fri, 17 Nov 2023 21:53:59 +0000 Subject: [PATCH] fix: set ignore_changes on EC2 example templates --- examples/templates/aws-linux/main.tf | 3 +++ examples/templates/aws-windows/main.tf | 3 +++ 2 files changed, 6 insertions(+) diff --git a/examples/templates/aws-linux/main.tf b/examples/templates/aws-linux/main.tf index cce6252c82649..de8f446d05986 100644 --- a/examples/templates/aws-linux/main.tf +++ b/examples/templates/aws-linux/main.tf @@ -255,6 +255,9 @@ resource "aws_instance" "dev" { # Required if you are using our example policy, see template README Coder_Provisioned = "true" } + lifecycle { + ignore_changes = [ami] + } } resource "coder_metadata" "workspace_info" { diff --git a/examples/templates/aws-windows/main.tf b/examples/templates/aws-windows/main.tf index 39e10f473fa26..1b9bb54021499 100644 --- a/examples/templates/aws-windows/main.tf +++ b/examples/templates/aws-windows/main.tf @@ -191,6 +191,9 @@ resource "aws_instance" "dev" { # Required if you are using our example policy, see template README Coder_Provisioned = "true" } + lifecycle { + ignore_changes = [ami] + } } resource "coder_metadata" "workspace_info" {