From eb3ea16e226137552cb58f452ce0d62c90b85de2 Mon Sep 17 00:00:00 2001 From: priyanshichauhan0707 Date: Tue, 13 Dec 2022 12:38:19 +0530 Subject: [PATCH] data files added --- terraform/msk/_override.tf | 7 +++++++ terraform/msk/backend.tf | 7 +++++++ terraform/msk/data_network.tf | 9 +++++++++ terraform/network_skeleton/backend.tf | 2 +- 4 files changed, 24 insertions(+), 1 deletion(-) create mode 100644 terraform/msk/_override.tf create mode 100644 terraform/msk/backend.tf create mode 100644 terraform/msk/data_network.tf diff --git a/terraform/msk/_override.tf b/terraform/msk/_override.tf new file mode 100644 index 00000000..04e6d04e --- /dev/null +++ b/terraform/msk/_override.tf @@ -0,0 +1,7 @@ +locals { + vpc_id = "${data.terraform_remote_state.network.outputs.vpc_id}" + kafka_SG_id = "${data.terraform_remote_state.network.outputs.web_sg_id}" + subnet_ids = "${data.terraform_remote_state.network.outputs.public_subnet_ids}" +} + + diff --git a/terraform/msk/backend.tf b/terraform/msk/backend.tf new file mode 100644 index 00000000..a62095f1 --- /dev/null +++ b/terraform/msk/backend.tf @@ -0,0 +1,7 @@ +terraform { + backend "s3" { + bucket = "bp-infra" + key = "elasticache/terraform.tfstate" + region = "us-west-2" + } +} diff --git a/terraform/msk/data_network.tf b/terraform/msk/data_network.tf new file mode 100644 index 00000000..41825f7c --- /dev/null +++ b/terraform/msk/data_network.tf @@ -0,0 +1,9 @@ +data "terraform_remote_state" "network" { + backend = "s3" + + config = { + bucket = "bp-infra" + key = "network/terraform.tfstate" + region = "us-west-2" + } +} \ No newline at end of file diff --git a/terraform/network_skeleton/backend.tf b/terraform/network_skeleton/backend.tf index 660fa02c..46c8c71d 100644 --- a/terraform/network_skeleton/backend.tf +++ b/terraform/network_skeleton/backend.tf @@ -1,6 +1,6 @@ terraform { backend "s3" { - bucket = "bp-step-tfstate" + bucket = "bp-infra" key = "network/terraform.tfstate" region = "us-west-2" }