Skip to content
Permalink
Browse files

Do not cache amp separately for desktop and mobile, content is always…

… the same
  • Loading branch information
FlorianSW committed Nov 27, 2019
1 parent 3f27dbb commit c13c8947e4477bd7731dd96142b2889b6b36c764
Showing with 1 addition and 1 deletion.
  1. +1 −1 modules/role/templates/varnish/default.vcl.erb
@@ -79,7 +79,7 @@ sub vcl_recv {
}

unset req.http.x-wap;
if (req.http.User-Agent ~ "(?i)^(lg-|sie-|nec-|lge-|sgh-|pg-)|(mobi|240x240|240x320|320x320|alcatel|android|audiovox|bada|benq|blackberry|cdm-|compal-|docomo|ericsson|hiptop|htc[-_]|huawei|ipod|kddi-|kindle|meego|midp|mitsu|mmp\/|mot-|motor|ngm_|nintendo|opera.m|palm|panasonic|philips|phone|playstation|portalmmm|sagem-|samsung|sanyo|sec-|sendo|sharp|softbank|symbian|teleca|up.browser|webos)") {
if (req.http.User-Agent ~ "(?i)^(lg-|sie-|nec-|lge-|sgh-|pg-)|(mobi|240x240|240x320|320x320|alcatel|android|audiovox|bada|benq|blackberry|cdm-|compal-|docomo|ericsson|hiptop|htc[-_]|huawei|ipod|kddi-|kindle|meego|midp|mitsu|mmp\/|mot-|motor|ngm_|nintendo|opera.m|palm|panasonic|philips|phone|playstation|portalmmm|sagem-|samsung|sanyo|sec-|sendo|sharp|softbank|symbian|teleca|up.browser|webos)" && req.url !~ "(\?|&)(action=amp)") {
set req.http.x-wap = "no";
}

0 comments on commit c13c894

Please sign in to comment.
You can’t perform that action at this time.