-
-
Notifications
You must be signed in to change notification settings - Fork 997
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
How do we call submodules from the same terragrunt.hcl file? #3733
Comments
Hey @manzajohn , Try this: terraform {
source = "tfr:///terraform-aws-modules/eks/aws//modules/aws-auth?version=${local.source_version}"
} I'm not sure that |
That is what i tried in the separate terragrunt.hcl file, which throws the above error, my eks_cluster hcl file is having below
|
Notice that the file above has this:
Not this:
|
yes, tried the same, still same error I can see the errored file in cache folder
But as per the module example no such parameters are passed |
0
I was trying to migrate eks module from version 19 to 20, seems like there is a new submodule got introduced aws_auth in terraform aws eks module and need to remove aws_auth details from eks module. My current terragrunt.hcl file looks like this
How can i call this new submodule from the same terragrunt file?
https://registry.terraform.io/modules/terraform-aws-modules/eks/aws/latest/submodules/aws-auth
from the same terragrunt.hcl file? or what is the best way to achieve this?
i tried to create a separate folder and own terragrunt.hcl file like below
Also i have added dependency as eks module in this file but still
This gave me below error while terragrunt plan
Error: Reference to undeclared resource │ │ on k8s-provider.tf line 4, in provider "kubernetes": │ 4: host = try(aws_eks_cluster.this[0].endpoint, null) │ │ A managed resource "aws_eks_cluster" "this" has not been declared in the │ root module.
What is the best solution for this?
The text was updated successfully, but these errors were encountered: