I'm currently running Drupal 4.6.6, Drupal 4.7 RC3 and CivicSpace 0.8.3 . I preferred to have one set of source files, but I wanted each site (Apache vhost) to have its own root folder.

So, with some symlink magic, here's what I do. Each version of Drupal has its own directory under my servers web root. I have the following directories and symlinks:

  • drupal-4.6.6
  • drupal-4.7.0-rc3
  • civicspace-0.8.3
  • drupal-4.6 -> drupal-4.6.6
  • drupal-4.7 -> drupal-4.7.0-rc3
  • civicspace -> civicspace-0.8.3

Each vhost has its own DocumentRoot with the following symlinks, substituting drupal-4.6 or civicspace for drupal-4.7 as appropriate:

  • cron.php -> ../drupal-4.7/cron.php
  • database -> ../drupal-4.7/database
  • includes -> ../drupal-4.7/includes
  • index.php -> ../drupal-4.7/index.php
  • misc -> ../drupal-4.7/misc
  • modules -> ../drupal-4.7/modules
  • scripts -> ../drupal-4.7/scripts
  • sites -> ../drupal-4.7/sites
  • themes -> ../drupal-4.7/themes
  • update.php -> ../drupal-4.7/update.php
  • xmlrpc.php -> ../drupal-4.7/xmlrpc.php

Each vhost gets its own files/ directory, robots.txt, .htaccess and favicon.ico files.

Now, when the next version (e.g. 4.7.1) is released I can unpack the files, copy the sites folder from the previous version, and then update the version symlink (drupal-4.7 -> drupal-4.7.1) and run the update.php script.

If I want to change a particular site from Drupal 4.6 or CivicSpace 0.8.3 to Drupal 4.7 I update the symlinks in the DocumentRoot to point to the 4.7 series, copy the appropriate site config file over and run the update.php script.

This is working well so far, but in my recent "Memory Hogging" blog I mention that having too many modules installed (even if not activated) make the admin/modules screen take up tons of RAM. My sites have different modules needs, so I think I'm going to give each vhost its own modules directory and then symlink the modules under that. This way I'll have only one module version per drupal version in my filesystem and be able to remove modules I know don't need from individual sites.