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

Fix: single_nat_gateway with enable=false attribute #62

Merged
merged 1 commit into from
Nov 1, 2023

Conversation

h1manshu98
Copy link
Member

what

  • Updated single_nat_gateway creation condition when enable = false is used for below error -

│ Error: Error in function call

│ on ../../main.tf line 319, in resource "aws_nat_gateway" "private":
│ 319: subnet_id = length(aws_subnet.public) > 0 ? element(aws_subnet.public[*].id, count.index) : element(var.public_subnet_ids, count.index)
│ ├────────────────
│ │ while calling element(list, index)
│ │ count.index is 0

│ Call to function "element" failed: cannot use element function with an empty list.

@h1manshu98 h1manshu98 requested a review from a team November 1, 2023 16:44
@clouddrove-ci clouddrove-ci self-assigned this Nov 1, 2023
Copy link
Member

@13archit 13archit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link

@omsharma07 omsharma07 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@omsharma07 omsharma07 merged commit 1103c7a into master Nov 1, 2023
24 checks passed
@delete-merged-branch delete-merged-branch bot deleted the fix/single-nat-gateway branch November 1, 2023 17:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants