CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Multi-Site functionality »
  • Automate Multisite Installs
Pages: [1]

Author Topic: Automate Multisite Installs  (Read 4466 times)

mcaden

  • Guest
Automate Multisite Installs
August 27, 2010, 01:23:44 am
I'm trying to create a php script to automate civicrm multisite setups on drupal.  Most of it can simply be taken from the AddNewOrgToMultiSite.php file located in the bin directory.  I'm dynamically creating the civicrm.settings.php file accurately.

The part I'd like to find out is if scripts are available that have already implemented something like this including setting up the ACL and the navigation menus.

Eileen

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4195
  • Karma: 218
    • Fuzion
Re: Automate Multisite Installs
August 27, 2010, 04:12:24 am
I don't think so, I've always done the navigation menus 'by hand'
Make today the day you step up to support CiviCRM and all the amazing organisations that are using it to improve our world - http://civicrm.org/contribute

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Automate Multisite Installs
August 27, 2010, 07:40:33 am

i know that jamie has been doing some work on automated setup and config. I've asked him to respond here

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

jamie

  • I post occasionally
  • **
  • Posts: 95
  • Karma: 6
Re: Automate Multisite Installs
August 27, 2010, 07:51:46 am
I'm working with Progressive Tech Project/Our Power base to deploy civicrm - (progress so far is in an attachment here: http://forum.civicrm.org/index.php/topic,15269.0.html). But - we're not using the mulit-org feature - so I haven't delved into ACLs. I'm very interested to see how this progresses though!

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Automate Multisite Installs
August 27, 2010, 04:31:01 pm

seems like there are at least 3 groups doing something similar (automated install with a specific setup). might be worth it if folks describe in detail their goals and assumptions so we can coordinate and hopefully have one group working on a combined spec :) and maybe improve core to make things easier

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

mcaden

  • Guest
Re: Automate Multisite Installs
August 27, 2010, 05:58:24 pm
I need to have this within the next couple days.  I didn't want to waste time if it had already been done elsewhere or if there were API calls already in existence.  For example I mentioned the PHP file included in the bin directory which already sets up the domain, organization, group, and assigns the organization as the group contact.  I added to this automatic creation of the civicrm.settings.php file and was hoping to find the ACL stuff already done for me.

I plan on adding the menu building which should be easy.

It's the ACL stuff I can't find.  I also can't find it in the API.

When I get this accomplished I'll post it.  If somebody can give me a boost, awesome.  If not, so be it.

Eileen

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4195
  • Karma: 218
    • Fuzion
Re: Automate Multisite Installs
August 27, 2010, 07:53:37 pm
The ACLs are managed by the multisite module
Make today the day you step up to support CiviCRM and all the amazing organisations that are using it to improve our world - http://civicrm.org/contribute

xcf33

  • I post frequently
  • ***
  • Posts: 181
  • Karma: 7
  • CiviCRM version: 3.3.2
  • CMS version: Drupal 6.19/6.20
  • MySQL version: 5.x
  • PHP version: 5.2.6
Re: Automate Multisite Installs
August 30, 2010, 06:18:48 am
I've been doing some automated CiviCRM upgrade via drush on multiple sites across multiple servers.


But the cork in it is that all the servers the sites are hosted on (doesn't matter shared or dedicated) need to have shell_exec enabled and php has to have sufficient privilege to run command like wget and tar


It your system requirements fit, it is possible to use drush to do automatic install with configuration preloaded in the civi SQL files.


Cheers!

mcaden

  • Guest
Re: Automate Multisite Installs
September 02, 2010, 09:55:53 pm
Quote from: Eileen on August 27, 2010, 07:53:37 pm
The ACLs are managed by the multisite module

All I see in the multisite module is information gathering...select statements.

mcaden

  • Guest
Re: Automate Multisite Installs
September 03, 2010, 12:10:38 am
So I've been looking into simply creating the necessary table entries.  I seem to be missing a table. I see a table that ties control over a group, gives it a name, and specifies the level of control.  I see another table that ties the acl to what group it's assigned to.  What I don't see is the table that links the 2.  The related columns:

civicrm_acl.object_id = civicrm_acl_entity_role.entity_id= group  ... this looks like a couple set.

civicrm_acl.entity_id = civicrm_acl_entity_role.acl_role_id = ...????  Where exactly does this tie in? 

It looks like it's creation of the actual ACL role but there's no table for it.


Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Automate Multisite Installs
September 03, 2010, 07:04:52 am

the acl roles are stored in the option group and value table (civicrm_option_group, civicrm_option_value) under the group_name 'acl_role'

ping us on irc if u have more questions, might be quicker and faster that way

lobo

A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

mcaden

  • Guest
Re: Automate Multisite Installs
September 09, 2010, 11:36:24 pm
Thanks for all the help.

I've now got a Drupal module that automatically sets up a child on a drupal/civicrm multisite (org, domain, group, group nesting, menus, ACLs, and drupal permissions).

If people want it I can supply it after I do a bit more testing.  I also need to make it more robust before I release it as right now certain things like permissions are hard-coded.

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: Automate Multisite Installs
September 10, 2010, 02:03:14 am
That would be nice.

Are you using it with aegir ?

X+
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

mcaden

  • Guest
Re: Automate Multisite Installs
September 10, 2010, 02:35:53 am
Drupal 6 - single install multisite
CiviCRM 3.1.4 - single install multisite

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Multi-Site functionality »
  • Automate Multisite Installs

This forum was archived on 2017-11-26.