Closed aknysh closed 6 years ago
Fascinating! We're using this module already, so maybe is due to newer versions of TF.
provider "aws" needs to be used from a top-level module. This module is a lower-level module provider "aws" causes cycles in
terraform plan
andterraform apply
Actually, this is the wrong conclusion. The regression was introduced by https://github.com/cloudposse/terraform-aws-efs-backup/commit/03a667bc12ead9084372dc5b84c5435ee64339cf#diff-7a370d8342e7203b805911c92454f0f4R6
The problem is that the aws_region
data source depends on the provider
data source. The provider
resource is setting the region of the aws_region
data source. Thus there's a catch 22 (cycle).
It should also be noted that both sides of a ternary are evaluated by terraform even if the condition is false. That's why the RHS of the ternary is executed and fails with the cycle error.
What
provider "aws"
README.md
Why
provider "aws"
needs to be used from a top-level module. This module is a lower-level moduleprovider "aws"
causes cycles interraform plan
andterraform apply
, throwing the error:email
is required indatapipeline_config
. Otherwise the module fails with the error: