From 02befde583470d6eecfa04a687a3adeb4d01d006 Mon Sep 17 00:00:00 2001 From: David Ficociello Date: Wed, 13 Sep 2017 09:32:21 -0400 Subject: [PATCH] fixed a few syntax errors with quotes and adjusted user_data block to be template_file --- bootstrapping/aws/resources.tf | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/bootstrapping/aws/resources.tf b/bootstrapping/aws/resources.tf index 7ee3ec5..c5f0f60 100644 --- a/bootstrapping/aws/resources.tf +++ b/bootstrapping/aws/resources.tf @@ -73,7 +73,7 @@ resource "aws_db_instance" "estate" { username = "${db_user}" password = "${db_password}" vpc_security_group_ids = ["${aws_security_group.estate.name}"] - db_subnet_group_name = ${aws_db_subnet_group.estate.id} + db_subnet_group_name = "${aws_db_subnet_group.estate.id}" skip_final_snapshot = "true" backup_retention_period = 0 copy_tags_to_snapshot = "true" @@ -113,7 +113,7 @@ resource "aws_elasticache_cluster" "estate" { } } -data "user_data" "estate" { +data "template_file" "estate" { template = "${file("${path.module}/../shared/scripts/bootstrap.sh")}" vars { @@ -133,7 +133,7 @@ resource "aws_instance" "estate" { ebs_optimized = true disable_api_termination = true root_block_device { - volume_type = gp2 + volume_type = "gp2" volume_size = "20" delete_on_termination = true } @@ -143,7 +143,7 @@ resource "aws_instance" "estate" { private_key = "${file("${var.key_path}")}" } - user_data = "${data.user_data.estate.rendered}" + user_data = "${data.template_file.estate.rendered}" tags { Name = "${var.tagName}-${count.index}"