-
Notifications
You must be signed in to change notification settings - Fork 5
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: add load balancer and configuration for deploying cloudfront distribution #232
Conversation
@smohiudd I'm not sure if the issue is what I think, but when deploying API Gateway with custom domain name, I usually need update the |
Thanks @vincentsarago, I wasn't aware of this feature in API gateway. It looks like that solves the issue that we're having. The ABL was just a test to try something similar to CSDA but if the API gateway parameter mapping is easier to implement that might be the way to go. |
@vincentsarago 🤯 THAT WORKED! I'd been struggling with this issue for a while, thanks so much!!!! |
@smohiudd i implemented it in ghg center, hope it helps! stac_api_integration = aws_apigatewayv2_integrations_alpha.HttpLambdaIntegration(
construct_id,
handler=lambda_function,
parameter_mapping=aws_apigatewayv2_alpha.ParameterMapping().overwrite_header(
"host",
aws_apigatewayv2_alpha.MappingValue.custom(veda_stac_settings.host),
)
if veda_stac_settings.host
else None,
) |
To overcome the issue of the cloudfront base url not being passed to API gateway, this PR instead uses an application load balancer (which was inspired by the work done in CSDA). It also fixes the trailing slash redirect issue we were having with API gateway.
This has been deployed to the
path-prefix
stack and currently working at: https://delta-backend.xyz/Some things to note: