- 최신
- 최다 투표
- 가장 많은 댓글
Hi,
Setting up APEX to www and viceversa redirection with Cloudfront may seem a trivial task but it is far from it in AWS!
In my experience, rather than creating a hack with an empty S3 bucket which redirects to the target origin, I would rather setup a CloudFront function that handles the redirection: https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/example-function-redirect-url.html.
The 2 possible approaches are explained here too: https://aws.amazon.com/premiumsupport/knowledge-center/cloudfront-redirect-domain/
Hope it clarifies
Make sure your Security group on your ALB for www.mydomain.com allows access from cloudfront. Also ensure that the ECS container's SG has access from the same ALB in question also.
Ensure your ALB rules are setup and send requests to the containers. If using custom headers for permission, ensure the correct HTTP Headers are on your alb rules also
관련 콘텐츠
- AWS 공식업데이트됨 일 년 전
- AWS 공식업데이트됨 일 년 전