terragruntArchived
5 messages
Terragrunt discussions
Archive: https://archive.sweetops.com/terragrunt/
Amit Karpeabout 5 years ago
Do we have AWS Profile option using Terragrunt?
I am ware that using Terraform, we can use provider block:
Where we can specify profile name.
How I can change that in the terragrunt.hcl?
Is there any way we can override it during
I am ware that using Terraform, we can use provider block:
provider "aws" {
profile = "default"
region = "us-west-2"
}Where we can specify profile name.
How I can change that in the terragrunt.hcl?
Is there any way we can override it during
terragrunt apply or any run time operation?Yoni Leitersdorf (Indeni Cloudrail)about 5 years ago
Am new to Terragrunt. Trying to run Cloudrail as part of my Terragrunt flow to test plans before they are applied. I have three modules -
So am running this:
And I’ve added this after_hook:
But:
1. The execution of the Cloudrail container is all over the place. It’s hard to know which module the Cloudrail output belongs to without using
2. The whole concept of passing to apply a plan I created in a previous step doesn’t seem to be working.
Am I missing something?
item1, item2, item3. Cloudrail needs to take in the plan.out out as its input, and spits out some stdout content as well as an exit code. Based on this exit code, I want to move forward to apply.So am running this:
terragrunt run-all plan -out plan.out
terragrunt run-all apply -auto-approve plan.outAnd I’ve added this after_hook:
terraform {
after_hook "cloudrail_after_hook" {
commands = ["plan"]
execute = [
"docker",
"run",
"--rm",
"-v", "${get_env("PWD", "")}:/data",
"indeni/cloudrail-cli",
"run",
"-d", "${path_relative_to_include()}",
"--tf-plan", "${path_relative_to_include()}/plan.out",
"--origin", "ci",
"--build-link", "<https://somelink>",
"--execution-source-identifier", "somebuildnumber - tg module ${path_relative_to_include()}",
"--api-key", "${get_env("CLOUDRAIL_API_KEY", "")}",
"--auto-approve"
]
}
}But:
1. The execution of the Cloudrail container is all over the place. It’s hard to know which module the Cloudrail output belongs to without using
--terragrunt-log-level info.2. The whole concept of passing to apply a plan I created in a previous step doesn’t seem to be working.
Am I missing something?
M
Mohammed Yahyaabout 5 years ago
@Mohammed Yahya has joined the channel
Asisabout 5 years ago(edited)
Hi Everyone
Our team runs terragrunt modules locally , what are the best solutions/ practice to run modules in more unified pattern
Note we have s3bucket + dynamodb for locking state
Thanks in Advance
Our team runs terragrunt modules locally , what are the best solutions/ practice to run modules in more unified pattern
Note we have s3bucket + dynamodb for locking state
Thanks in Advance
Tim Gourleyalmost 5 years ago(edited)
Hi All,
I’ve been looking at Atlantis for automation with our Terragrunt configurations.
The recommended approach seems to be to plan individual projects.
Atlantis can do some parallel operations but it is real fuzzy to me if that actually works (workspaces get pulled into the conversation etc)
I have a test configuration with about 24 modules and the Atlantis plan takes ~30 minutes since it processes each model in sequence.
I did get some parallel operations but then there were lock contentions, and the workspace topic freaks me out as I understood that is not something you do when using Terragrunt.
So, what am I missing, am I using a hammer to drive a screw?
Why is plan-all not discussed?
I do understand the shortcomings of unapplied modules affecting dependent modules in the plan but I think this is one of the choices we make when we move to Terragrunt.
Any suggestions on a more appropriate automation tooling for Terragrunt managed envs?
TIA, Tim
I’ve been looking at Atlantis for automation with our Terragrunt configurations.
The recommended approach seems to be to plan individual projects.
Atlantis can do some parallel operations but it is real fuzzy to me if that actually works (workspaces get pulled into the conversation etc)
I have a test configuration with about 24 modules and the Atlantis plan takes ~30 minutes since it processes each model in sequence.
I did get some parallel operations but then there were lock contentions, and the workspace topic freaks me out as I understood that is not something you do when using Terragrunt.
So, what am I missing, am I using a hammer to drive a screw?
Why is plan-all not discussed?
I do understand the shortcomings of unapplied modules affecting dependent modules in the plan but I think this is one of the choices we make when we move to Terragrunt.
Any suggestions on a more appropriate automation tooling for Terragrunt managed envs?
TIA, Tim