-
-
Notifications
You must be signed in to change notification settings - Fork 119
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
feat(terraform): adds ignore_default_action input variable #140
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -40,23 +40,23 @@ | |
|
||
output "http_listener_arn" { | ||
description = "The ARN of the HTTP forwarding listener" | ||
value = one(aws_lb_listener.http_forward[*].arn) | ||
value = join("", aws_lb_listener.http_forward.*.arn, aws_lb_listener.http_forward_ignore_default_action.*.arn) | ||
Check warning on line 43 in outputs.tf
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @jbrt for all of these lint errors, you do want to use brackets instead of |
||
} | ||
|
||
output "http_redirect_listener_arn" { | ||
description = "The ARN of the HTTP to HTTPS redirect listener" | ||
value = one(aws_lb_listener.http_redirect[*].arn) | ||
value = join("", aws_lb_listener.http_redirect.*.arn, aws_lb_listener.http_redirect_ignore_default_action.*.arn) | ||
Check warning on line 48 in outputs.tf
|
||
} | ||
|
||
output "https_listener_arn" { | ||
description = "The ARN of the HTTPS listener" | ||
value = one(aws_lb_listener.https[*].arn) | ||
value = join("", aws_lb_listener.https.*.arn, aws_lb_listener.https_ignore_default_action.*.arn) | ||
} | ||
|
||
output "listener_arns" { | ||
description = "A list of all the listener ARNs" | ||
value = compact( | ||
concat(aws_lb_listener.http_forward[*].arn, aws_lb_listener.http_redirect[*].arn, aws_lb_listener.https[*].arn) | ||
concat(aws_lb_listener.http_forward.*.arn, aws_lb_listener.http_redirect.*.arn, aws_lb_listener.https.*.arn, aws_lb_listener.http_forward_ignore_default_action.*.arn, aws_lb_listener.http_redirect_ignore_default_action.*.arn, aws_lb_listener.https_ignore_default_action.*.arn) | ||
) | ||
} | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Huh this is beyond the scope of your PR, but noting for myself and any fellow contributors: I'm not even sure why we need to have two of these resources for http_forward + http_redirect. It seems we could just do the conditional logic In the default action itself without requiring two resources.
@joe-niland do you happen to know the history behind why it was done this way?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Gowiem sorry I missed this one! I don't know why but it dates back to the initial implementation I think. I agree it could be refactored as you described.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@joe-niland I'll create an issue and we can see if a passer by wants to pick it up!