Aegir Platforms

Events happening in the community are now at Drupal community events on www.drupal.org.
steven jones's picture

I saw the DrupalCon DC presentation and was very impressed by Aegir. We're currently evaluating systems that can help us deploy sites to our servers quickly and easily, and then keep them up to date.

I have got Aegir working on my system, and have installed a site using it, it was all relatively pain-free. My question is thus:

Is Aegir built to deploy sites onto identical platforms, i.e. without any site specific code? Or is there a way to add certain modules to specific sites but keeping them on the same core platform of modules?

Comments

Relative symlinks

adrian's picture

I've been pondering this actually.

Relative symlinks is the only way to handle it sanely. I've been thinking we should have a 'server' checkout path for all the modules and themes we install, and then symlink to the correct version of the module.

We still need to tackle the dependency stuff first before we can think about this, and this has implications for importing sites on existing platforms.

The security issues of symlinks

Rainy Day's picture

What about the security implications of using symbolic links? I believe using symlinks under Apache is generally frowned upon in security circles. As far as i know, Drupal core doesn’t use symlinks, so one might want to configure their server with symlinks turned off.

Running Apache in a chroot jail would mitigate the concerns, but that is relatively uncommon. As far as i know, the only OS to chroot Apache on install is OpenBSD. Using SymLinksIfOwnerMatch is a middle-ground measure, i suppose.

It would be very tricky to manage code without symlinks

adrian's picture

Could lead to all kinds of issues with outdated code that isn't being found correctly, and would lead to multiple checkouts of the same code all over the system. (something we generally try to avoid).

I wish Drupal had a mechanism for extending the systems table through the settings.php file, as that would be a preferable solution.
A recent patch to core added a sites.php file which allows you to map site directories through code, instead of path searching.

We could look at a patch like that for Drupal 7, but for D5/D6 we will still be stuck with symlinks.

--
The future is so Bryght, I have to wear shades.

Also, install profiles

boris mann's picture

Also, depending on how many sites and how many are the same, install profiles can be used to collect sets of modules.

Aegir per se doesn't solve it, but who does?

totten's picture

I don't know anything about your background, but it sounds like you're in the same position I am (i.e. somewhat new to multi-site management on Drupal). I'm going to try writing a more novice-level response to this (mainly b/c it helps me polish my understanding).

Or is there a way to add certain modules to specific sites but keeping them on the same core platform of modules?

Yes, there is a way to add certain modules to specific sites, but Aegir per-se doesn't facilitate it. Some options (in order of decreasing maintainability):

a) Put the source code in root/sites/all/modules -- but exercise prudence in when you enable the module.

b) Put the source code in root/profiles/example/modules -- and plan your profiles before deploying.

c) Put the source code in root/sites/example.com/modules -- and accept that you'll have to do some footwork to manage updates

These three options provide coverage for several use-cases, but they can break down in a few situations:

1) You want to mix-and-match different versions of the same module across many sites on one platform.

2) You want to mix-and-match different feature bundles (10 modules + a theme + some CCK/views config) across many sites on one or more platforms.

None of this is really a drawback of Aegir, though. You've got to deal with the same issues whether you're deploying with Aegir, custom Perl scripts, Capistrano, Maven, or any of the other bazillion tools that can copy around files. In fact, these Drupal-specific issues are what led me to Aegir: on any other platform that comes to mind, you have to design and implement your own solutions to these problems. With Aegir, there's some hope that other developers will be working on the same problems.

Thanks for the replies, I

steven jones's picture

Thanks for the replies, I was really asking if I could add specific modules to a site using Aegir (within the web UI), and I guess the answer is yes, by implementing a nodeapi hook to go grab the site's modules from someplace (or getting drush to do that) and putting them in the /sites/example directory.

Have you done this yet, can

krisbfunk's picture

Have you done this yet, can you provide example code?

Aegir hosting system

Group organizers

Group categories

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: