0
votes

I have CloudFront distribution with multiple domains. As example all domains like .mydomain.com caching in my distribution. And now I have problem with invalidation. I can't set invalidation path like this one.mydomain.com or http://one.mydomain.com. Every times when I need invalidate cache I must invalidate cache for everyone domais which I have. With the path /

But my site provide page editor, and I want invalidate page after each save in editor. How can I invalidate cache for individual domain?

1

1 Answers

0
votes

First of all, it is currently not possible to invalidate by domain and Cloudfront invalidation by path only.

If you plan to automate the invalidation once a page is saved, you can use the AWS SDK for CloudFront and call the createInvalidation method from your code.