Cloudfront - Invalidate Cache on Git Commit via Lambda

By ReginaHack, 29 June, 2020

To be able to directly see the new blog posts, the CloudFront Cache needs to be invalidated.

To avoid having to do it manually, I setup a Lambda function that gets triggered via the CodePipeline after the deploy stage.

Invalidate CloudFront Cache using lambda

Checkout the article here to grab your Lambda function to invalidate CF Cache and the IAM policy.