For my site now Boost module is working fine. It wasn't working though it was indeed generating the HTML files. I tracked it to .httaccess rule:

RewriteCond %{HTTPS} on [OR]

After commenting out it's working fine. But any idea why it is made to skip specifically HTTPS sites?

I will mention the D6 Boost .htaccess rules:


  # NORMAL - Cached css & js files
  RewriteCond %{DOCUMENT_ROOT}/cache/perm/%{HTTP_HOST}%{REQUEST_URI}_\.css -s
  RewriteRule .* cache/perm/%{HTTP_HOST}%{REQUEST_URI}_\.css [L,QSA,T=text/css]
  RewriteCond %{DOCUMENT_ROOT}/cache/perm/%{HTTP_HOST}%{REQUEST_URI}_\.js -s
  RewriteRule .* cache/perm/%{HTTP_HOST}%{REQUEST_URI}_\.js [L,QSA,T=text/javascript]

  # Caching for anonymous users
  # Skip boost IF not get request OR uri has wrong dir OR cookie is set OR request came from this server OR https request
  RewriteCond %{REQUEST_METHOD} !^(GET|HEAD)$ [OR]
  RewriteCond %{REQUEST_URI} (^/(admin|cache|misc|modules|sites|system|openid|themes|node/add|comment/reply))|(/(edit|user|user/(login|password|register))$) [OR]
  RewriteCond %{HTTPS} on [OR]
  RewriteRule .* - [S=1]

  RewriteCond %{DOCUMENT_ROOT}/cache/normal/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.html -s
  RewriteRule .* cache/normal/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.html [L,T=text/html]

  ### BOOST END ###

I've had to comment out RewriteCond %{HTTPS} on [OR]

  • 1
    It would be easier to guess the problem if you explain how Boost is failing when that line is enabled. – sanzante Aug 25 '20 at 8:25
  • If this condition is true then it does not send the HTML file from disk eventhough it has been generated. – user5858 Aug 25 '20 at 10:46
  • It looks like maybe this was added intentionally 11 years ago: drupal.org/project/boost/issues/516670 – sonfd Aug 25 '20 at 11:22
  • I’m voting to close this question because this appears to be a bug in the module and should be resolved in the d.o issue queue – sonfd Aug 25 '20 at 11:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.