-
Notifications
You must be signed in to change notification settings - Fork 28
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
Terragrunt files #34
Comments
Hi @nilsdebruin, sorry about the late response - last month was a busy one for me.. I had a look at how Terragrunt does config parsing, and it looks like it actually provides a way to parse just those
I think we should be able to generate The meat of it is the file pkg/scan/terragrunt.go, the rest of the diff consists almost entirely of changes to vendored packages. Here's how its output looks right now: $ terraform-module-versions -terragrunt=true list examples
$ terraform-module-versions -terragrunt=true check examples
|
Hi @sgreben, don't worry, thank you for your time and effort! I am really appreciating that you are taking the time to dive into this. As I am not a Go developer, I can only look at it from a functional perspective. I checked out your code, build it, and tested it on a directory with .hcl files. I can validate that it works for this first example, really cool! I have included a more elaborate example in the examples directory which I have submitted as a PR: #39. This is a more extended example, which is based on the following repo: https://github.com/gruntwork-io/terragrunt-infrastructure-live-example. When I run the Terragrunt version as follows:
I get the following output:
I think this is due to the fact that a terragrunt function is triggerd which is present in the .hcl file, namely:
I am unsure if this can turned off and that the file can be scanned / parsed as is. I can imagine that this is quite a complex problem, so I understand if you just leave it at the first iteration (which in my opinion is already very cool!) |
This would be great feature man. Let me know if I can help somehow, but my Go knowledge is near to zero :( |
It could be interesting to include terragrunt.hcl files to the version check. Terragrunt files have the following terraform configuration block (this is an example):
terraform {
source = "git@github.com:terraform-aws-modules/terraform-aws-iam.git//modules/iam-assumable-roles?ref=v2.21.0"
}
Do you know how this could be implemented?
The text was updated successfully, but these errors were encountered: