Deny caching on mime-type
Hauke Lampe
lampe at hauke-lampe.de
Fri Mar 23 12:43:20 CET 2012
On 23.03.2012 11:29, Shibashish wrote:
> I have a IIS back-end server which serves a aspx file Content-Type as
> text/html or text/vnd.wap.wml depending on the browser request, i.e it
> serves Content-Type text/vnd.wap.wml to a wap-browser, but serves
> Content-Type text/html to chrome/firefox/ie.
>
> How do I ask varnish not to cache based on mime-tyme text/vnd.wap.wml ?
You shouldn't. Have IIS add a "Vary: User-Agent" header, so that varnish
caches the different versions.
You might want to normalize the User-Agent header in vcl_recv() to
reduce the number of variants and improve cache efficiency, but that's
not strictly necessary.
Hauke.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: OpenPGP digital signature
URL: <https://www.varnish-cache.org/lists/pipermail/varnish-misc/attachments/20120323/7ddea89f/attachment.pgp>
More information about the varnish-misc
mailing list