New command graph
has wrong parameter documentation (+ potential anomaly when running in monorepo)
#3342
Labels
awaiting response
Waiting for a response or more data from issue reporter
bug
Something isn't working
Describe the bug
Let me start by saying thank you for the great value and improvements you provide to the community with terragrunt!
My first remark is that the documentation for the new command
terragrunt graph <command>
states--graph-root
as a parameter for the root (by default the git root dir), but it should be--terragrunt-graph-root
.My second remark is that I encountered a weird phenomenon within my monorepo where I have in the git-root three completely decoupled environment directories:
terragrunt graph plan
escaped my current env-directory and travesed into another env-directory.Steps To Reproduce
For the first remark:
For the second remark:
In my git root directory I have no
terragrunt.hcl
. For each environmentdev
,test
, andprod
, I have a dedicated directory, each with a rootterragrunt.hcl
.When inside a deep directory
dir-1
withindev
which depends on anotherdir-2
insidedev
and thisdir-2
is refering a local file next to its ownterragrunt.hcl
usingget_terragrunt_dir()
, e.g., a SOPS encrypted secret like this:then terragrunt ended up in
test
trying to fetch thesecrets.yaml
found insidetest
environment.When I run with
then this anomaly does not happen.
Expected behavior
For my first remark:
Either the documentation is updated or the command accepts the key specified at the moment in the documentation.
For my second remark:
Running
terragrunt graph plan
in a mono-repo containing several envs should not attempt to touch files in a neighbouring environment directory.Nice to haves
For my first remark:
terragrunt-graph-root
terragrunt/cli/commands/graph/command.go
Line 27 in e0c5cbe
For my second remark:
I might try creating a hello-world example but lack time right now (also to rule out any other anomalies due to my setup). Till then I was hoping that some experienced person could tell me if this is a false-positive and
terragrunt graph
is meant to behave like that.Versions
Additional context
n/a
The text was updated successfully, but these errors were encountered: