Here's a technical one...... Multisite or Domain Access?

We encourage users to post events happening in the community to the community events group on https://www.drupal.org.
BigChief's picture

Here's an interesting challenge:

Site 1 has subdomains that will not share the user table, but will share modules.

Site 2 has a different domain, but will share the user table with site 1, and has different modules but will share some page content.

They are currently on two different servers, but I can place them on the same machine to share DB etc.

From what I have read I have a hybrid of the functionality between the two approaches.

Multisite or Domain Access? Which one should be used to do the trick here....

Thanks in advance for your tips!

Comments

Multisite or Domain Access

manuel_mra's picture

Hi:
It could be posible two ways:
1.- Using SSO.
2.- Using Multisite for both sites and for the first one use the same DB for subbdomains and for the second site use two DB, the first site DB an another one (multidatabases). Then make a hook to share both users.

Manuel.

Hmmm - but...

BigChief's picture

Thanks Manuel....

The only issue I have is that the SSO project has not been maintained since Drupal 7 came out (according to the project page) and the last update was in 2009.... (only Drupal 5 & 6 module available).

Here is another module that might be worth considering (but it means learning LDAP):
https://drupal.org/project/ldap_sso
It is also intended for intranet applications where the need exists for Active Directory integration.

Looks like I should end up with your option #2:
Using Multisite for both sites and for the first one use the same DB for subbdomains and for the second site use two DB, the first site DB an another one (multidatabases). Then make a hook to share both users.

My concern is the last part of your statement - make a hook to share both users!
Any pointers on that please?

This is what Drupal.org uses

Mark Theunissen's picture

This is what Drupal.org uses for SSO: https://drupal.org/project/bakery

If you're trying to combine

Garrett Albright's picture

If you're trying to combine two currently-existing sites and don't want to re-architecture a new site, multisite is going to be the best approach. That being said, sharing database tables between sites, though known to be done successfully from time to time, is something I generally recommend avoiding, so yeah, a SSO approach would probably be best.

If it's not a big deal to re-architecture a site, then I think that Domain Access is the simplest, sanest approach in any case where you want to share content and/or users between sites.

Combining.....

BigChief's picture

@Garrett - thanks for the thought process.... I had not thought that I might combine both into one site! Overlooking the obvious, I guess! It makes total sense, because it then allows one database, and one site to manage...

But - how do you host the same site under two different domain names, with a different theme for each domain, and a different landing page? Does Domain Access provide that functionality?

OK - getting my thoughts straight:
1. adapt the functionality of both sites into a single Drupal instance (1 site)
2. both domains point at the same website
3. if Domain1 is used, then the user logs in with common user name password and sees Theme1+ SiteContent1.
4. if Domain2 is used, then the user logs in with common user name password and sees Theme2+ SiteContent2.
5. the user switches between the domains if he wants to see the other side - simply using a link to the other domain!

OK - now how do I get that right? Is Domain Access able to do that? Is Drupal able to do that?

Your thinking is correct,

Garrett Albright's picture

Your thinking is correct, yes. Domain Access works by looking at what domain name the visitor is using to access the site when Drupal is bootstrapped and changing variables such as the site name and default theme and such accordingly. It sounds complex, and some parts of it are, but its core functionality is actually pretty simple to understand.

You've got me thinking, though....

BigChief's picture

If I were to combine both sites content into one Drupal site, and point both domains at the website, then I would benefit the most!

I started searching for multiple domains on one Drupal site, and found a couple of interesting other options:

https://drupal.org/project/virtual_site
This seems to do exactly what we're talking about (in one module!).

If I were to combine it with something like
https://drupal.org/project/curlypage
Then I could maybe switch between the two domains (which are related) in quite a nice smart way!

This has the outcome of:
1. One Drupal site to maintain
2. Two (inter-related) sites that look very similar, but are for used different purposes
3. One user table, and permissions to look after.
4. One database to backup, maintain and keep tidy!
5. One website data (files) to backup and maintain.

I will need to study Domain access in a little more detail.

Thanks so much for your prompts!

I have been creating Drupal sites for around 3-4 years now, but I am not a developer..... just used standard modules, and customised the settings for around 7 or 8 sites. Some were quite smart, since the combination of Drupal Modules can make for some very clever functionality! Quite amazing to see how the community works, too... thanks for your inputs and guidance!

I looked at that Virtual Site

Garrett Albright's picture

I looked at that Virtual Site module (had never heard of it before)… It seems to be somewhere between the standard Drupal multi-site system and Domain Access in functionality, though not really explaining why it's a better choice than either (it claims that the configuration for standard Drupal multi-sites is complex; it is not). At any rate, it has a lot less usage than those other two methods. The folks in this group can help you backwards and forwards with those other two methods, but maybe not so much with VS, if you need it. But use what works best for you.

If you do decide to use that Curlypage module, please let me know what the URL of your sites are, so I can be sure to never ever visit them.

@ Garrett...

BigChief's picture

Thanks for the feedback - I won't use the Curlypages, then!

I am still trying to determine what the most effective way will be to deploy the two sites (or maybe one site) and two domains. I don't have the skills to switch between systems halfway, so I need to choose one and stick with it.

Does the Domain Access approach permit same signon to both Drupal 7 and Drupal 6 sites? There is a module for both versions, and they work off the DA API. From the uninitiated, perhaps this might be a good idea if future sites will be D7?

Setup of Domain Access seems a little tricky. I also don't see anything that relates to sites hosted on Windows IIS7.5 and Domain Access. Is it possible to use IIS? Drupal works fine on IIS7.5 as standalone.

With regards to single sign

Garrett Albright's picture

With regards to single sign on, I don't see how that would be a problem. You say "if future sites will be D7…" Are you saying that this site isn't a Drupal 7 one? Dude… time to upgrade!

I don't know much about IIS configuration, but I don't think it should be a problem. You just have to make sure that all domain names point to the same Drupal installation directory. Groups.Drupal.org has Microsoft Servers and Drupal on Windows groups, with the latter appearing to be more active; if you ask there, you may find someone else who has set up DA on IIS and can give you more specific information.

Thanks so much Garrett

BigChief's picture

I have done the development in Drupal6 so far, and not really ventured into D7, since it seemed like a whole new kettle of fish. I guess I will need to get a whole new site going, and combine the content from both D6 sites into the new D7... the two sites that I am going to combine are www.sabeex.co.za and www.cmentor.co.za

I started a photo website a couple of years back, at www.afripixel.com to showcase Sony Alpha cameras and allow people with Sony cameras to post in a dedicated South African location. That's where my Drupal journey started.... and it has not really progressed past D6, as I got a little stuck in the upgrades of the Image Module (which really is the main core of that website!). I guess I need to look into the upgrade of that one as well....

Phew - my learning curve seems to be becoming a little steeper all the time!

I really do appreciate your help and guidance.