Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unintended .tfimport files for *.tfvars configuration #168

Open
eistrati opened this issue Feb 23, 2020 · 0 comments
Open

Unintended .tfimport files for *.tfvars configuration #168

eistrati opened this issue Feb 23, 2020 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@eistrati
Copy link
Contributor

Describe the Bug

Unintended .tfimport files for *.tfvars configuration

To Reproduce

My landing_zone_components variable looks something like this:

landing_zone_components = {
  landing_zone_vpc    = "s3://terraform-aws-landing-zone/components/landing_zone_vpc/*.tfvars"
  [...]
}

After running terraform apply, I am expecting to see something like this:

$ git diff components/landing_zone_vpc
diff --git a/components/landing_zone_vpc/.terrahub.yml b/components/landing_zone_vpc/.terrahub.yml
index c1943c9..6062599 100644
--- a/components/landing_zone_vpc/.terrahub.yml
+++ b/components/landing_zone_vpc/.terrahub.yml
@@ -47,3 +47,13 @@ component:
         value: >-
           { for vpc in aws_vpc.landing_zone_vpc.*: lookup(vpc.tags, "LzHash",
           vpc.cidr_block) => vpc.arn }
+terraform:
+  varFile:
+    - >-
+      s3://terraform-aws-landing-zone/components/landing_zone_vpc/default.tfvars

Instead, I'm seeing unintended .tfimport files, something like this:

$ git diff components/landing_zone_vpc
diff --git a/components/landing_zone_vpc/.terrahub.yml b/components/landing_zone_vpc/.terrahub.yml
index c1943c9..6062599 100644
--- a/components/landing_zone_vpc/.terrahub.yml
+++ b/components/landing_zone_vpc/.terrahub.yml
@@ -47,3 +47,13 @@ component:
         value: >-
           { for vpc in aws_vpc.landing_zone_vpc.*: lookup(vpc.tags, "LzHash",
           vpc.cidr_block) => vpc.arn }
+terraform:
+  varFile:
+    - >-
+      s3://terraform-aws-landing-zone/components/landing_zone_vpc/default.tfimport
+    - >-
+      s3://terraform-aws-landing-zone/components/landing_zone_vpc/default.tfvars
@eistrati eistrati added the bug Something isn't working label Feb 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants