Is possible configure the cache-control header by page?
Nope, please add a feature request here: https://github.com/getgrav/grav/issues
@rhuk what about this?
By default, Grav will cache the contents of the page file to ensure things run as fast as possible. There are advanced scenarios where you do not want the page to be cached.
An example of this is when you are using dynamic Twig variables in your content. The
cache_enablevariable allows this behavior to be overridden. We will cover Twig Content variables in a later chapter. Valid values are
I think @jrivero is referring to HTTP headers
May be But I was looking for a way to disable cache on a single page myself today, so I’m sharing what I’ve found
Yes, my understanding was he was looking for the cache-control header option to be set by page. That option is an internal grav cache enable/disable by page.
Yes, I need define the time (max-age), and if cacheable (public, private, etc.) on each page type for the browser and varnish. I have some pages that change a lot and is interesting have a cache of 1 hour and other that change little a cache of 1 day.
This has been added and works in conjunction with expires: https://github.com/getgrav/grav/commit/13341c323d43eb47562d8ae72eae730e3e0e2cee