Single multisite "site," answers to xxx.tld and yyy.tld

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

Here's one for folks to chew on before tomorrow's Boulder meeting - is there a way to have a multisite instance at xxx.tld (that is to say, the multisite directory is sites/xxx.tld) also serve the site for yyy.tld? I've seen symlinking used to similar effect in the past, but that appears to be a bit of a hack to me.

I'd think there's a way to accomplish this using mod_rewrite or mod_proxy, but I'm reaching the limits of my expertise there.

Anyone have an idea on how to get apache to internally rewrite yyy.tld to xxx.tld so Drupal will serve up the intended site? Cross-2nd-level-domain sites work for "sites/default," so why not here? :-)

Comments

Couldn't you do a 301

protitude's picture

Couldn't you do a 301 redirect with the .htaccess file or with in your apache conf file if you prefer?

Depends on the Version...

jcfiala's picture

In drupal 7, you can use the sites.php file (In the sites directory) to point both tlds to the same path.

In Drupal 6, it's harder. You could set it up as two different directories under the sites folder, with almost-the-same settings.php files, and symlink the files directory. Or, you could have them both working out of sites/default, which is where requests will go if you don't have a specific directory named.

-john

Well whaddaya know, that file

bradjones1's picture

Well whaddaya know, that file is indeed new in Drupal 7 and it was lurking there under my nose the whole time. Old habits die hard I suppose! Thanks.

Drupal Colorado

Group notifications

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