How do you add CloudFront in front of API Gateway

后端 未结 5 1534
情话喂你
情话喂你 2020-11-28 20:49

API Gateway (APIG), while it uses CloudFront (CF) it does not support CDN edge caching. When I configured a CF distribution to use APIG as the custom origin, I get a permiss

5条回答
  •  暖寄归人
    2020-11-28 20:54

    I just want to reiterate here, for anyone who's following the guide from AWS premium support knowledge center,

    How do I set up API Gateway with my own CloudFront distribution? https://aws.amazon.com/premiumsupport/knowledge-center/api-gateway-cloudfront-distribution/

    If you are using AWS console to set up the CloudFront distribution, the root cause is that you set Cache Based on Selected Request Headers to all.

    Setting it to None or exclude the Host header in the Whitelist would solve the problem.

提交回复
热议问题