From 3a9a84f56f7d78abd4be5e452ab6f6514998dab5 Mon Sep 17 00:00:00 2001 From: Jaden VanEckhout Date: Tue, 30 Apr 2024 18:47:29 -0500 Subject: [PATCH] fix: ignore cookies in image cache policy (#212) --- src/NextjsDistribution.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/NextjsDistribution.ts b/src/NextjsDistribution.ts index d265b8e6..27489bd7 100644 --- a/src/NextjsDistribution.ts +++ b/src/NextjsDistribution.ts @@ -348,7 +348,7 @@ export class NextjsDistribution extends Construct { new cloudfront.CachePolicy(this, 'ImageCachePolicy', { queryStringBehavior: cloudfront.CacheQueryStringBehavior.all(), headerBehavior: cloudfront.CacheHeaderBehavior.allowList('accept'), - cookieBehavior: cloudfront.CacheCookieBehavior.all(), + cookieBehavior: cloudfront.CacheCookieBehavior.none(), defaultTtl: Duration.days(1), maxTtl: Duration.days(365), minTtl: Duration.days(0),