-
Notifications
You must be signed in to change notification settings - Fork 6
tf-plan in eks cluster policy.tf error #6
Comments
|
You need to use This will only work up until the |
|
Its gives the same error.
starting v1.4.4 action plan file logs/plan.20221025.1666706579.log stamp 20221025.1666706579 time 1666706579Warning: Provider source not supported in Terraform v0.12 on .terraform/modules/group_cluster-admin/versions.tf line 3, in terraform: A source was declared for provider aws. Terraform v0.12 does not support the (and 6 more similar warnings elsewhere) Error: Invalid function argument on policy.tf line 152, in locals: Invalid value for "v" parameter: cannot convert string to list of any single Error: Too many function arguments on policy.tf line 155, in locals: Function "tolist" expects only 1 argument(s). Error: Too many function arguments on policy.tf line 155, in locals: Function "tolist" expects only 1 argument(s). Error: Too many function arguments on policy.tf line 155, in locals: Function "tolist" expects only 1 argument(s). Error: Too many function arguments on policy.tf line 155, in locals: Function "tolist" expects only 1 argument(s). ending v1.4.4 action plan file logs/plan.20221025.1666706579.log stamp 20221025.1666706579 start 1666706579 end 1666706586 elapsed 7results in file logs/plan.20221025.1666706579.log stamp 20221025.1666706579 status=0= Complete: 14 POLICY> | status=0 |
|
Please show me your |
|
and explain how you populated the directory for this new EKS cluster. |
|
This is my setting.auto.tfvars file. I copied full cluster example code to APP Directory as demonstrated in TWG Knowledge sharing sessions. [shaik005@catlab001 tco-ent-auth]$ cat settings.auto.tfvars |
|
esk-tf-run14.txt Attached tf-run apply 14 output Note that the -target option is not suitable for routine use, and is provided Error: error creating IAM Policy p-eks-tco-ent-auth-cluster-admin: MalformedPolicyDocument: Policy statement must contain resources. on policy.tf line 57, in resource "aws_iam_policy" "cluster-admin-policy":
= Complete: 14 POLICY> | status=0 |
|
updated the code and reran tf-run plan 14. Getting this error. A source was declared for provider aws. Terraform v0.12 does not support the (and 6 more similar warnings elsewhere) Error: Invalid for_each argument on .terraform/modules/group_cluster-admin/main.tf line 55, in resource "aws_iam_group_policy_attachment" "this": The "for_each" value depends on resource attributes that cannot be determined Error: Invalid for_each argument on .terraform/modules/role_cluster-admin/main.tf line 167, in resource "aws_iam_role_policy_attachment" "role": The "for_each" value depends on resource attributes that cannot be determined Error: Invalid for_each argument on .terraform/modules/role_eks-cluster/main.tf line 167, in resource "aws_iam_role_policy_attachment" "role": The "for_each" value depends on resource attributes that cannot be determined ending v1.4.4 action plan file logs/plan.20221104.1667569575.log stamp 20221104.1667569575 start 1667569575 end 1667569591 elapsed 16 |
Describe the bug
tf-plan on eks cluster creation gives error "Invalid value for "v" parameter: cannot convert string to list of any single
type"
Identify Environment
terraform -version]: `Terraform v0.12.31Your version of Terraform is out of date! The latest version
is 1.3.3. You can update by downloading from https://www.terraform.io/downloads.html`
git remote -v show]:origin git@github.e.it.census.gov:terraform/079788916859-do2-cat.git (fetch)
origin git@github.e.it.census.gov:terraform/079788916859-do2-cat.git (push)
git branch]: cat-test-ekspwd]: /vpc/east-1/vpc4/apps/tco-ent-authExpected behavior
tf-plan runs with no errors.
Screenshots

Server (please complete the following information):
Additional context
`Error: Invalid function argument
on policy.tf line 152, in locals:
152: tolist(format(local.common_arn, "eks", format("/clusters/%v/addons", var.cluster_name))),
Invalid value for "v" parameter: cannot convert string to list of any single
type.
Error: Too many function arguments
on policy.tf line 155, in locals:
153:
154:
155: format(local.common_arn, "eks", format("%v/%v/*", r, var.cluster_name))
156:
Function "tolist" expects only 1 argument(s).
Error: Too many function arguments
on policy.tf line 155, in locals:
153:
154:
155: format(local.common_arn, "eks", format("%v/%v/*", r, var.cluster_name))
156:
Function "tolist" expects only 1 argument(s).
Error: Too many function arguments
on policy.tf line 155, in locals:
153:
154:
155: format(local.common_arn, "eks", format("%v/%v/*", r, var.cluster_name))
156:
Function "tolist" expects only 1 argument(s).
Error: Too many function arguments
on policy.tf line 155, in locals:
153:
154:
155: format(local.common_arn, "eks", format("%v/%v/*", r, var.cluster_name))
156:
Function "tolist" expects only 1 argument(s).`
The text was updated successfully, but these errors were encountered: