I am reading about AWS Cloudfront and how does that invalidate the Cache. Read a few articles that all seems to indicate that event triggered from S3 can be subscribed by a Lambda that perform the cache invalidation. For example here and here.
This works for a website hosted in S3.. However I have a web app that is hosted in Docker (Tomcat container) containers on AWS. This Web app gets a new release every month, or sometime more than a month depending upon new requirements.
I believe Cloudfront will also cache the static files for this Website, for example, Images, CSS and JS files. My question is, how do we invalidate the Cloudfront cache for this website after releases? One way I could think of is writing a Script that is part of the Install job to invalidate the cache during release process. Let me know your views and if there is a better way to achieve this?
Related discussions:
- What are you using for backups to S3?
- Should connection from cloudfront to origin(ALB) over SSL?
- Optimizing S3 Storage Classes?
- AWS suspended our production account for “non-payment”. We paid the invoice in full, billing shows R$0.00 due, and AWS Health says our EKS control plane shuts down in two days.
- S3 Glacier Deep Archive - Are these the Costs Involved? Am I missing anything?