Hi,
I’m creating below module and getting provider version issue when run terraform init
module "lb_role" {
source = "terraform-aws-modules/iam/aws//modules/iam-role-for-service-accounts-eks"
version = " 5.5.0 "
role_name = "${var.resource_prefix}_eks_lb"
attach_load_balancer_controller_policy = true
oidc_providers = {
main = {
provider_arn = module.eks_cluster.oidc_provider_arn
namespace_service_accounts = ["kube-system:aws-load-balancer-controller"]
}
}
}
│ Error: Failed to query available provider packages
│
│ Could not retrieve the list of available versions for provider hashicorp/aws: no available releases match the given constraints >= 3.13.0, >= 3.56.0, >= 4.0.0, < 4.0.0
╵
and I do see the hashicorp/aws versions are used in the stage in different places.
command terraform providers lists below
Providers required by configuration:
.
├── provider[registry.terraform.io/hashicorp/aws]
├── provider[registry.terraform.io/hashicorp/kubernetes]
├── provider[registry.terraform.io/hashicorp/helm]
├── module.eks_cluster
│ ├── provider[registry.terraform.io/hashicorp/aws]
│ └── module.eks
│ ├── provider[registry.terraform.io/terraform-aws-modules/http] >= 2.4.1
│ ├── provider[registry.terraform.io/hashicorp/aws] >= 3.56.0
│ ├── provider[registry.terraform.io/hashicorp/local] >= 1.4.0
│ ├── provider[registry.terraform.io/hashicorp/kubernetes] >= 1.11.1
│ ├── provider[registry.terraform.io/hashicorp/cloudinit] >= 2.0.0
│ ├── module.node_groups
│ │ ├── provider[registry.terraform.io/hashicorp/aws] >= 3.56.0
│ │ └── provider[registry.terraform.io/hashicorp/cloudinit] >= 2.0.0
│ └── module.fargate
│ └── provider[registry.terraform.io/hashicorp/aws] >= 3.56.0
├── module.lb_role
│ └── provider[registry.terraform.io/hashicorp/aws] >= 4.0.0
├── module.cloudwatch_logs
│ ├── provider[registry.terraform.io/hashicorp/helm] >= 1.0.0, < 3.0.0
│ ├── provider[registry.terraform.io/hashicorp/kubernetes] >= 1.10.0, < 3.0.0
│ └── provider[registry.terraform.io/hashicorp/aws] >= 3.13.0, < 4.0.0
├── module.instance_role
│ └── provider[registry.terraform.io/hashicorp/aws]
├── module.cluster_vpc_network
│ └── provider[registry.terraform.io/hashicorp/aws]
├── module.metric_set_table
│ └── provider[registry.terraform.io/hashicorp/aws]
├── module.msk_cluster
│ ├── provider[registry.terraform.io/hashicorp/aws]
│ └── module.msk_log_group
│ └── provider[registry.terraform.io/hashicorp/aws]
├── module.condition_table
│ └── provider[registry.terraform.io/hashicorp/aws]
└── module.device_model_table
└── provider[registry.terraform.io/hashicorp/aws]
Providers required by state:
provider[registry.terraform.io/hashicorp/aws]
provider[registry.terraform.io/hashicorp/cloudinit]
provider[registry.terraform.io/hashicorp/helm]
provider[registry.terraform.io/hashicorp/kubernetes]
provider[registry.terraform.io/hashicorp/local]
provider[registry.terraform.io/terraform-aws-modules/http]
tried with different versions but throws same error, can someone help
thanks!