The should work for you if you get a content type and length from backend. This
works on varnish 2.15
I placed this is my fetch block.
# Don't cache html objects smaller than 100 bytes
if ((beresp.status == 200) && (beresp.http.Content-Length ~
"^([0-2]|\d)\d") && ( beresp.http.Content-type ~ "html") ) {
log "TooSmall: Pass on ( " req.url " ) small objects: "
beresp.http.Content-Length ;
return(pass);
}
Richard
_______________________________________________
varnish-misc mailing list
[email protected]
https://www.varnish-cache.org/lists/mailman/listinfo/varnish-misc