Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
yorinasub17 committed Feb 14, 2020
1 parent d575a46 commit 68fe15e
Show file tree
Hide file tree
Showing 18 changed files with 91 additions and 27 deletions.
1 change: 1 addition & 0 deletions test/fixture-codegen/generate-block/nested/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
random_file.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
generate "random_file" {
path = "random_file.txt"
if_exists = "overwrite"
contents = "Hello world"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
generate "backend" {
path = "backend.tf"
if_exists = "overwrite"
contents = <<EOF
terraform {
backend "local" {
path = "bar.tfstate"
}
}
EOF
}

generate "random_file" {
path = "random_file.txt"
if_exists = "overwrite"
contents = "Hello world"
}
15 changes: 15 additions & 0 deletions test/fixture-codegen/generate-block/nested/root.hcl
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
generate "backend" {
path = "backend.tf"
if_exists = "overwrite"
contents = <<EOF
terraform {
backend "local" {
path = "foo.tfstate"
}
}
EOF
}

terraform {
source = "${get_parent_terragrunt_dir()}/../../module"
}
2 changes: 2 additions & 0 deletions test/fixture-codegen/generate-block/overwrite/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
foo.tfstate
bar.tfstate
5 changes: 5 additions & 0 deletions test/fixture-codegen/generate-block/overwrite/backend.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
terraform {
backend "local" {
path = "bar.tfstate"
}
}
11 changes: 11 additions & 0 deletions test/fixture-codegen/generate-block/overwrite/terragrunt.hcl
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
generate "backend" {
path = "backend.tf"
if_exists = "overwrite"
contents = <<EOF
terraform {
backend "local" {
path = "foo.tfstate"
}
}
EOF
}
15 changes: 15 additions & 0 deletions test/fixture-codegen/generate-block/skip/terragrunt.hcl
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
generate "backend" {
path = "main.tf"
if_exists = "skip"
contents = <<EOF
terraform {
backend "local" {
path = "foo.tfstate"
}
}
EOF
}

terraform {
source = "../../module"
}
File renamed without changes.
4 changes: 4 additions & 0 deletions test/fixture-codegen/remote-state/base/terragrunt.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,7 @@ remote_state {
path = "foo.tfstate"
}
}

terraform {
souce = "../../module"
}
4 changes: 4 additions & 0 deletions test/fixture-codegen/remote-state/error/terragrunt.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,7 @@ remote_state {
path = "foo.tfstate"
}
}

terraform {
souce = "../../module"
}
7 changes: 0 additions & 7 deletions test/fixture-codegen/remote-state/overwrite/main.tf

This file was deleted.

4 changes: 4 additions & 0 deletions test/fixture-codegen/remote-state/overwrite/terragrunt.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,7 @@ remote_state {
path = "foo.tfstate"
}
}

terraform {
souce = "../../module"
}
7 changes: 0 additions & 7 deletions test/fixture-codegen/remote-state/s3/main.tf

This file was deleted.

4 changes: 4 additions & 0 deletions test/fixture-codegen/remote-state/s3/terragrunt.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,7 @@ remote_state {
}
}
}

terraform {
souce = "../../module"
}
13 changes: 0 additions & 13 deletions test/fixture-codegen/remote-state/skip/main.tf

This file was deleted.

4 changes: 4 additions & 0 deletions test/fixture-codegen/remote-state/skip/terragrunt.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,7 @@ remote_state {
path = "foo.tfstate"
}
}

terraform {
souce = "../../module"
}

0 comments on commit 68fe15e

Please sign in to comment.