Skip to content
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

data "aws_availability_zones" needs to be created when referenced #215

Closed
kzehnter opened this issue Aug 22, 2023 · 2 comments
Closed

data "aws_availability_zones" needs to be created when referenced #215

kzehnter opened this issue Aug 22, 2023 · 2 comments
Labels
bug Something isn't working good first issue Good for newcomers help wanted Extra attention is needed

Comments

@kzehnter
Copy link

Expected Behaviour:
When the conversion utilizes data.aws_availability_zones.available.names the following data block gets created as well.

data "aws_availability_zones" "available" {
  state = "available"
}

Actual Behaviour:
The data block does not get created so the code doesn't work.

Found with this conversion:

      AvailabilityZone: !Select 
        - 0
        - !GetAZs ''

to

  availability_zone = element(data.aws_availability_zones.available.names, 0)
@shadycuz
Copy link
Member

Thanks for reporting this.

@shadycuz shadycuz added bug Something isn't working good first issue Good for newcomers help wanted Extra attention is needed labels Sep 11, 2023
@shadycuz
Copy link
Member

I can't seem to replicate this as I do see the data block being added. But I do see a bug in the name of the data block

data "availability_zones" "available" {
  state = "available"
}

Should be aws_availability_zones.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants