Skip to content

Restore AWS required version #180

@jasondamour

Description

@jasondamour

Description

#178 removed the required_providers block, which now causes the following warning in my env:

│ Warning: Reference to undefined provider
│ 
│   on aws_ecs_cluster.tf line 16, in module "ecs_cluster":
│   16:     aws = aws.us_east_2
│ 
│ There is no explicit declaration for local provider name "aws" in module.ecs_cluster, so Terraform is assuming you mean to pass a
│ configuration for "hashicorp/aws".
│ 
│ If you also control the child module, add a required_providers entry named "aws" with the source address "hashicorp/aws".

Versions

  • Module version [Required]:
    5.10.0

  • Terraform version:
    Terraform v1.7.4

  • Provider version(s):
    + provider registry.terraform.io/hashicorp/aws v5.41.0

Reproduction Code [Required]

module "ecs_cluster" {
  # https://github.com/terraform-aws-modules/terraform-aws-ecs
  source  = "terraform-aws-modules/ecs/aws"
  version = "~> 5.0"

  providers = {
    aws = aws.us_east_2
  }

  cluster_name = "us-east-2-fargate-cluster"
}

Expected behavior

No warning

Actual behavior

Warning printed.

Additional

Tagging @bryantbiggs since your PR removed the block, can you shed some light on that?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions