Cache-Control Caddy Reverse Proxy and Ghost caching settings


I can see Cache-Control by Caddy Reverse-Proxy and those set by Ghost. if i set to “no cache” some parts of website, I still get cache max age settings from Ghost. Should I disable Ghost’s cache settings or perhaps disable caddy caching?

This what I got for the image file. As you can see Cache-Control is doubled.

HTTP/2 200
accept-ranges: bytes
cache-control: public, max-age=604800, must-revalidate #### That's Caddy Proxy setting
cache-control: public, max-age=31536000 ##### It was added by Ghost CMS, I think.
content-security-policy: default-src https: 'unsafe-inline' 'unsafe-eval'
content-type: image/jpeg
date: Thu, 18 Mar 2021 19:47:23 GMT
etag: W/"19d00-178268f9512"
expect-ct: max-age=604800
feature-policy: accelerometer 'none'; autoplay 'none'; camera 'none'; encrypted-media 'none'; fullscreen 'self'; geolocation 'none'; gyroscope 'none'; magnetometer 'none'; microphone 'none'; midi 'none'; payment 'none'; picture-in-picture *; sync-xhr 'none'; usb 'none'
last-modified: Fri, 12 Mar 2021 13:10:47 GMT
referrer-policy: same-origin
strict-transport-security: max-age=31536000; includesubdomains; preload
x-content-type-options: nosniff
x-frame-options: SAMEORIGIN
x-powered-by: the Holy Spirit
x-robots-tag: noarchive, notranslate
x-xss-protection: 1; mode=block
content-length: 105728

What does your Caddyfile look like? Usually, there’s no need of any custom cache control overrides on reverse proxy layer.

Indeed, I am not sure Ghost caching is good enough, if it does then maybe I do not need proxy caching.

thanks my issue has been fixed.