From 9d45081f272b01b482f62e809bc4b8bd953abc21 Mon Sep 17 00:00:00 2001 From: Andrew Dryga Date: Thu, 28 Sep 2023 21:13:58 -0600 Subject: [PATCH] Remove usage of deprecated terraform provider --- terraform/modules/elixir-app/main.tf | 8 ++------ terraform/modules/relay-app/main.tf | 6 +----- 2 files changed, 3 insertions(+), 11 deletions(-) diff --git a/terraform/modules/elixir-app/main.tf b/terraform/modules/elixir-app/main.tf index 46f4968d4..398f13785 100644 --- a/terraform/modules/elixir-app/main.tf +++ b/terraform/modules/elixir-app/main.tf @@ -132,11 +132,7 @@ resource "google_project_iam_member" "cloudtrace" { member = "serviceAccount:${google_service_account.application.email}" } -# Deploy the app -data "template_file" "clout-init" { - template = file("${path.module}/templates/cloud-init.yaml") -} - +# Deploy app resource "google_compute_instance_template" "application" { project = var.project_id @@ -213,7 +209,7 @@ resource "google_compute_instance_template" "application" { } }) - user-data = data.template_file.clout-init.rendered + user-data = templatefile("${path.module}/templates/cloud-init.yaml", {}) google-logging-enabled = "true" # Enable FluentBit agent for logging, which will be default one from COS 109 diff --git a/terraform/modules/relay-app/main.tf b/terraform/modules/relay-app/main.tf index b86ad5d95..108120de5 100644 --- a/terraform/modules/relay-app/main.tf +++ b/terraform/modules/relay-app/main.tf @@ -149,10 +149,6 @@ resource "google_compute_subnetwork" "subnetwork" { } # Deploy app -data "template_file" "clout-init" { - template = file("${path.module}/templates/cloud-init.yaml") -} - resource "google_compute_instance_template" "application" { for_each = var.instances @@ -235,7 +231,7 @@ resource "google_compute_instance_template" "application" { } }) - user-data = data.template_file.clout-init.rendered + user-data = templatefile("${path.module}/templates/cloud-init.yaml", {}) google-logging-enabled = "true" # Enable FluentBit agent for logging, which will be default one from COS 109