I'm looking to improve my deployment process, which currently uses Capistrano to deploy from a hosted git repository. For the most part, this is working pretty well.

However, I'm running into problems with deploying WP-Supercache:

  • Activating the WP-Supercache plugin creates a file advanced-cache.php in the wp-content folder that includes an absolute (and server specific path) to a file in the WP-Supercache plugin folder.
  • Cache files are stored in wp-content/cache which I'm (correctly) excluding from git.

The searching I've done has shown me a couple of possible alternatives for advanced-cache.php

  • Have the deployment task create the advanced-cache.php file each time (through the use of a template).
  • On the initial deployment, have the plugin create the correct file on the server, then move it to a shared folder and have a deployment task that symlinks to it.

For the cache files, the strategy seems to be to move the cache folder to the shared folder and add a deployment task to symlink it.

So, does anyone have a good solution / process for this - doesn't necessarily need to be Capistrano related, I think this issue surfaces for any deployment that includes WP-Supercache.

closed as off-topic by Johannes Pille, birgire, Pieter Goosen, Nicolai, s_ha_dum Oct 6 '14 at 17:34

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Your question should be specific to WordPress. Generic PHP/JS/HTML/CSS questions might be better asked at Stack Overflow or another appropriate site of the Stack Exchange network. Third party plugins and themes are off topic." – Johannes Pille, birgire, Pieter Goosen, Nicolai, s_ha_dum
If this question can be reworded to fit the rules in the help center, please edit the question.

  • 1
    Sure, this is off-topic. It's only a big problem for deploying any type of WP caching plugin. I guess people who don't deal with deploying WP don't really understand the issue. – anu Oct 7 '14 at 15:18

I use WP-SuperCache and since I just use (don't hack it), then it's deactivated when I'm on development. I only activate it on production. This might not be quite effective, because you may want to test how caching works on development. However, I found (at least for me) testing in development to be useless since the data and traffic are in the production and not in the development.

So, it might not be an answer, but if you are not doing any hacking for the plugin code, you may want to skip it in development and only activate it in production.

Not the answer you're looking for? Browse other questions tagged or ask your own question.