Skip to content

INFRA-6062: Trim region suffix from cluster_name in Gateway API LB name prefix#96

Merged
marcin-janas merged 1 commit intomainfrom
fix/trim-region-suffix-from-cluster-name-in-gateway-api-lb-name-prefix
Mar 26, 2026
Merged

INFRA-6062: Trim region suffix from cluster_name in Gateway API LB name prefix#96
marcin-janas merged 1 commit intomainfrom
fix/trim-region-suffix-from-cluster-name-in-gateway-api-lb-name-prefix

Conversation

@marcin-janas
Copy link
Copy Markdown
Contributor

Requestor/Issue: https://linear.app/worldcoin/issue/INFRA-6062/create-gateway-api-albnlb-from-terraform-aws-eks
Tested (yes/no): yes
Description/Why: clusters following the <name>-<region> naming convention (e.g. tools-gatewayapi1-dev-us-east-1) exceed the 21-character gateway_api_lb_name_prefix limit because the region is included in the default prefix. ALB and NLB modules already strip the region, so this aligns behavior. The fix auto-trims the -<region> suffix from cluster_name before using it as the default gateway_api_lb_name_prefix, avoiding the precondition error without requiring callers to set the variable explicitly

…efix

Signed-off-by: Marcin Janas <marcin.janas@toolsforhumanity.com>
@marcin-janas marcin-janas self-assigned this Mar 26, 2026
@marcin-janas marcin-janas requested a review from a team as a code owner March 26, 2026 10:51
@marcin-janas marcin-janas requested review from drapek007 and tcharewicz and removed request for a team March 26, 2026 10:51
@github-actions github-actions bot added enhancement New feature or request patch labels Mar 26, 2026
@marcin-janas marcin-janas merged commit e40d6c5 into main Mar 26, 2026
9 checks passed
@marcin-janas marcin-janas deleted the fix/trim-region-suffix-from-cluster-name-in-gateway-api-lb-name-prefix branch March 26, 2026 11:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request patch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants