Reputation: 11
I'm developing a web site and i have setting up the following structure in production eviroment:
NGINX (listening 443,proxy_pass) -> Varnish (listening 80) -> NGINX (listenig 8080).
So i can serve via https cached content.
The problem is that i have noticed that google crome is not caching locally content served via SSL (Firefox does)
When i pointed to the 80 port , both, Firefox and Chrome caches the content but chrome does not cache when try 443.
Those are the headers i get for a testing image:
Serving by HTTP
Accept-Ranges:bytes
Age:28
Cache-Control:max-age=31536000
Content-Length:190667
Content-Type:image/jpeg
Date:Fri, 18 Dec 2015 12:06:49 GMT
ETag:"5673f678-2e8cb"
Expires:Sat, 17 Dec 2016 12:06:49 GMT
Last-Modified:Fri, 18 Dec 2015 12:05:12 GMT
Served by HTTPS
Accept-Ranges:bytes
Age:74
Cache-Control:max-age=31536000
Connection:keep-alive
Content-Length:190667
Content-Type:image/jpeg
Date:Fri, 18 Dec 2015 12:19:34 GMT
ETag:"5673f678-2e8cb"
Expires:Sat, 17 Dec 2016 12:06:49 GMT
Last-Modified:Fri, 18 Dec 2015 12:05:12 GMT
Anyone knows if this may be a config problem with my servers, or maybe its a chrome normal way of deal with SSL conections?
Thanks
Upvotes: 1
Views: 108
Reputation: 11
Finally i found the problem.
i remove from the response headers the "Vary: cookies" header and now chrome is locally caching the content served via HTTPS
Upvotes: 0