[support] Multi-Site question

Luke drupal at lists.tacticus.com
Sat Mar 13 20:58:53 UTC 2010


On Sat, 13 Mar 2010, Daniel Carrera wrote:

> Earnie Boyd wrote:
>> How do you prevent users from one academy working with others data now?

Do you have some way for that, or is it somewhat on the honor system?

>> Again, how do you filter the content for users now?
>
> I'm not sure I understand. You are saying that I will have a hard time
> knowing which users belong to which academy? If so, yes, that's a
> problem and I don't have a solution yet.

That question related to your current configuration, not the one you are 
trying to create.  What are you doing right now, to manage content and 
users, to prevent cross contamination between schools?

Answering that question, may provide some here with a better idea of how 
to advise you.

>> And take a look at http://drupal.org/project/domain which could be a
>> better solution for you.
>
> Thanks. Looks very interesting. I have a few questions:

(Earnie, I'd particularly appreciate your comments on the below described 
framework)

> 1. Can I choose /not/ to share users between domains?

I can not answer that, but I'd bet there is a way to categorize users so 
that they only have access to the content for their particular domain (the 
one they signed up on?) through some of the node access and taxonomy 
access modules.

If you would like users who login anywhere on the entire system (E.G. 
another school's page) to get automatically sent to their intended 
school's page, one of these should be able to take care of that for you:
http://drupal.org/project/login_destination
http://drupal.org/project/logintoboggan

> 2. Can I have admins for just one domain? The idea is that the "domain
> admin" would be able to add/edit users but only within his domain.

I'm not sure how you would pull that off.  I am thinking that if you had 
a taxonomy for schools, and had just one school set per user of the 
system, you might be able to find a way to make users with the add user 
permission, only be able to add users who also had that taxonomy field 
set.  I.E. every user that Joe from school1 added, would have school1 as 
their school taxonomy.  Then, since you're also doing access permission 
checks based on that taxonomy, that user will only be able to access 
content on school1.schools.org (or school1.org, or whatever).
Since the login module directs users which have the school taxonomy set to 
a valid school to that school's frontpage (E.G. 
http://school1.schools.org/ for any user with school1 set), you're covered 
on that angle.

The only part of this I am not sure can be done without definite custom 
code, is the user add inherits schools taxonomy portion.  Might need a 
small custom module for that.  Someone in the paid forum could probably do 
it for a reasonable fee.

Oh also, there is the issue of namespaces.
You might want to convert to using email addresses for login instead of 
usernames.  http://drupal.org/project/email_registration
Some slight changes to this module should allow it to generate a school 
based "real" username, instead of the email address lhs001, lhs002 system 
that it uses now.

  > 3. Can I get a list of users associated with one domain?

If you go the taxonomy route, a view with a filter for the schools 
taxonomy, set to display users with it set, would do the trick.

Also, if you are okay with using subdomains, the subdomains module 
(http://drupal.org/project/subdomain), mode 3, would take care of dividing 
content.  You would have to have new content auto tagged with the school 
taxonomy, of course, which again might require that same custom helper 
module.

Regards,

Luke


More information about the support mailing list