From 8b6ed6d0060a0f396ed0605573219155a0a9a964 Mon Sep 17 00:00:00 2001 From: Jorge Lustosa Date: Mon, 12 Mar 2012 14:04:26 -0300 Subject: problems when downloading pdf files, corrupting the file ... --- config/varnish64/varnish.inc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'config') diff --git a/config/varnish64/varnish.inc b/config/varnish64/varnish.inc index 24891215..27f41861 100644 --- a/config/varnish64/varnish.inc +++ b/config/varnish64/varnish.inc @@ -468,10 +468,10 @@ function sync_package_varnish() { #set static content var $vcl_recv_static_sufix=($vcl['staticache']=='no'?"pass":"lookup"); $vcl_recv_static ="\t#Enable static cache\n"; - $vcl_recv_static.="\t".'if (req.request=="GET" && req.url ~ "\.(css|js|txt|zip|pdf|rtf|flv|swf|html|htm)$") {'.$vcl_recv_static_prefix."\n\t\treturn($vcl_recv_static_sufix);\n\t\t}\n"; + $vcl_recv_static.="\t".'if (req.request=="GET" && req.url ~ "\.(css|js|txt|zip|rtf|flv|swf|html|htm)$") {'.$vcl_recv_static_prefix."\n\t\treturn($vcl_recv_static_sufix);\n\t\t}\n"; $vcl_recv_static.="\t".'if (req.request=="GET" && req.url ~ "\.(gif|jpg|jpeg|bmp|png|ico|img|tga|wmf|mp3|ogg)$") {'.$vcl_recv_static_prefix."\n\t\treturn($vcl_recv_static_sufix);\n\t\t}\n"; $vcl_fetch_static ="#Enable static cache\n"; - $vcl_fetch_static.='if (req.url ~ "\.(css|js|txt|zip|pdf|rtf|flv|swf|html|htm)$") {'."\n\tunset beresp.http.set-cookie;\n\t}\n"; + $vcl_fetch_static.='if (req.url ~ "\.(css|js|txt|zip|rtf|flv|swf|html|htm)$") {'."\n\tunset beresp.http.set-cookie;\n\t}\n"; $vcl_fetch_static.='if (req.url ~ "\.(gif|jpg|jpeg|bmp|png|ico|img|tga|wmf|mp3|ogg)$") {'."\n\tunset beresp.http.set-cookie;\n\t}\n"; switch ($vcl['staticache']){ -- cgit v1.2.3