N sites with 1 CiviCRM Database1. Single / First site installationSay site1.example.com which would be same as any other normal civicrm installation. Before visiting any civicrm url enable multisite by modifying civicrm_settings.php To NB - you may need to add this line if your site started out as an early CiviCRM version as the civicrm_settings.php file is not normally changed when you upgrade. 2. Insert a new domain record in civicrm db. For example3. Build navigation links for new domain/siteModify civicrm_codebase/sql/civicrm_navigation.mysql file and specify new domain, e.g To And import this file to your civicrm db 4. Locate sites directorySetup another site on drupal say site2.example.com. This will create sites/site2.example.com/ directory in drupal. 5. Locate civicrm settings file for site2Depending on how you would like to install civicrm for site 2, you could proceed to step A OR B. A. Manual CiviCRM installation for site2.example.com.
B. Auto + Manual CiviCRM installation for site2.example.com
6. Enable multi site for second siteModify located civicrm.settings.php file (for site2) to change following line - To 7. Register new domain / siteModify located civicrm.settings.php file (for site2) to change following line - to reflect the id of inserted domain record in step2. Assuming id is 2 for newly inserted record, the line would change to - 8. Register domain/site groupIn multi-org installation, it is required to have a top-level org/group to represent the multi-org hierarchy root. When you login to the site and go to "manage groups" screen, you will notice a group with the name as that of domain. System requires you to register this master group responsible for holding sub-groups/contacts. You need to set a different group for each site (including the master site). So edit CiviCRM_settings.php for each site as below. You can either edit this group or create your own group and register that. To register modify civicrm.settings.php file (for site2) to change following line - To Assuming master group id is 2 9. Associate an organization with the master groupTo represent a multi-org hierarchy, an organization could be connected to the master group (one-to-one relationship). To register the organization, To Assuming organization contact id is 2 10. Configure same UF account for all N sites (having same email address), be mapped to different civicrm contact -The default behavior for this case is to map the drupal account having same email address for N sites with same/one civicrm contact. To 11. Configure Access Control to restrict users on Site N to contacts in Site N's Site GroupThere is a separate Drupal module called multisite that automatically implements CiviCRM access control for multi-site installations, such that normal users on Site N are restricted to contacts in Site N's Site Group. Note that users with permission to view or edit all contacts bypass this access control. As of CiviCRM 3.0.2 this is not part of the CiviCRM tarball but is available through svn. |
Multi Site Installation
Labels
