How to audit terragrunt tree for modules and download them?

25 Views Asked by At

I have an extensive terragrunt tree, with lots of terragrunt.hcl files. Each has a source = "<some module>" referencing some terraform module.

I am looking to audit my modules, both determining upon which modules we depend, as well as information about those modules.

Is there a native way to do this within terragrunt, or some external tool?

I started doing this in script, but it does get messy.

  1. Run a find . -name terragrunt.hcl and then awk to get the value of source = "<module>"
  2. Do some processing on the value of <module> to download it and get information about it.

The first part is doable, if messy. The second part is particularly messy, especially since it follows unique formats like git::ssh::... or other structures. These already are understood by the terraform-world tools, so I was hoping there is something that does this already.

Is there anything that can do (at least parts of) this for me?

0

There are 0 best solutions below