Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Using Boost in conjunction with Domain Access.
Caching per domain is working nicely, however the .htaccess (which sets the Expires/Cache-Control headers) generated by Boost in the cache folder, is not being generated for all domains.
Looking at the code, one would have to submit a Boost settings form (boost_form_submit_handler()) on each domain to have it generated for each domain.
Comments
Comment #1
Anonymous (not verified) CreditAttribution: Anonymous commentedThat is correct along with boost_form_submit_handler being called by _boost_rmdir the internal cache clearing function.
By submission on any form on any boost form in admin, (since I don't have the domain access module installed), I would guess that if you had two sites, one at abc.example.com and one at def.example.com, that if you only visited the boost admin section at abc.example.com then you would one generate the .htaccess files for the subfolders under abc.example.com which makes sense as normally modules are enabled on a per domain basis, one site may not want boost.
The only solution is as you have pointed out, is to submit the form on each domain, or write a new module like ctools and path have their own versions to work with domain access. A workaround would be to copy a modified .htaccess file into /cache above normal, which should then not be removed during cache clearance and would provide coverage for the other domains but you would need to work on the FilesMatch directive as although Files
FilesMatch does not match /
(from http://httpd.apache.org/docs/2.2/sections.html )
You may be able to get around FilesMatch by using the wildcard function for http://httpd.apache.org/docs/2.2/mod/core.html#files
<Files ~ "\.(gif|jpe?g|png)$">
which may work for sub-directories. Really depends what you have physically in your cache folder.