Hello,
I have tried to set up the mentioned subdirectory-based Drupal multisite installation, e.g.
http://example.com - codebase, all Drupal files go to the Web root of the site, single copy for all the site (and the site-specific components go to the relevant sites/ subdirectory.
In sites/:
example.com.a/ directory with settings.php etc
example.com.b/ directory with settings.php etc
example.com.c/ directory with settings.php etc
to have the following separate sites with their own DB tables sets:
http://example.com/a
http://example.com/b
http://example.com/c
etc
The problem is, I can't set those up. No way doing that by straightforward unpacking the distribution, calling install.php to have these sites set up properly.
Also, if I create those sites DB content elsewhere and import it into the example.com's actual DB, I can't access them, either. The root installation will intercept the URLs and either display the corresponding existing document in root installation, or redirect me to '404' document.
I was recommended this workaround: to create symlinks first, i.e. in Web root
ln -s . a
ln -s . b
ln -s . c
etc
Then run installation like this
http://example.com/a/install.php
and so on.
But:
- this won't work in systems without symlinks
- this is not reflected in installation manual - not a hint how to actually create such kind of multisiting
Perhaps it would be a good idea either to implement this in regular way (if possible) or at least add to INSTALL.txt the necessary explanations/directions.
Until then, it seems that the only working approach is to copy codebase/modules/themes/etc to the respective subdirectories and correct RedirectBase in their .htaccess to allow such multisiting on any platform.
Thanks.
Comments
Comment #1
maartenvg commentedFeature requests go in HEAD.
Comment #2
Anonymous (not verified) commentedI think it's not a feature request for 7.x but a bug report for 6.x, since INSTALL.txt clearly describes this feature as already existing - but it doesn't work. I ran into the same issue just now.
7.x is still a long way to go - by 'fixing' it for 6.x we could also get some feedback before it goes into 7.x ...
Comment #3
damien tournoud commentedThe relevant paragraph in INSTALL.txt
The documentation is ample, but confusing in http://drupal.org/node/43816
In a nutshell you need to make sure that requests to http://example.com/{a,b,c} will all be handled by the index.php in your multisite drupal folder. This involves either setting up symlinks, or using apache aliases. Most shared hosting have some kind of interface to define apache aliases.
I agree this should be a little bit better documented in INSTALL.txt. Let's change this for D7, then backport for D6.
Comment #4
jhodgdonThis is a duplicate of #285053: Improve INSTALL.txt description of multi-site installation with subdirectories, which has more information on how to actually fix the problem rather than fixing the doc.