/[drupal]/contributions/profiles/hostmaster/hostmaster.profile
ViewVC logotype

Diff of /contributions/profiles/hostmaster/hostmaster.profile

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.33, Thu Feb 26 19:58:31 2009 UTC revision 1.34, Wed Apr 1 01:51:03 2009 UTC
# Line 1  Line 1 
1  <?php  <?php
2  // $Id: hostmaster.profile,v 1.32 2009/02/26 19:20:26 anarcat Exp $  // $Id: hostmaster.profile,v 1.33 2009/02/26 19:58:31 adrian Exp $
3    
4  /**  /**
5   * Return an array of the modules to be enabled when this profile is installed.   * Return an array of the modules to be enabled when this profile is installed.
# Line 101  function hostmaster_profile_final() { Line 101  function hostmaster_profile_final() {
101    
102    $node = new stdClass();    $node = new stdClass();
103    $node->uid = 1;    $node->uid = 1;
   $node->type = 'package_release';  
   $node->title = 'Drupal ' . VERSION;  
   $node->package = $package_id;  
   $node->version = VERSION;  
   $node->schema_version = drupal_get_installed_schema_version('system');  
   $node->status = 1;  
   node_save($node);  
   $release_id = $node->nid;  
   
   $node = new stdClass();  
   $node->uid = 1;  
104    $node->type = 'platform';    $node->type = 'platform';
105    $node->title = $_SERVER['HTTP_HOST'] . ' (Drupal ' . VERSION . ')';    $node->title = $_SERVER['HTTP_HOST'] . ' (Drupal ' . VERSION . ')';
106    $node->publish_path = $_SERVER['DOCUMENT_ROOT'];    $node->publish_path = $_SERVER['DOCUMENT_ROOT'];
107    $node->web_server = variable_get('hosting_default_web_server', 3);    $node->web_server = variable_get('hosting_default_web_server', 3);
   $node->release_id = $release_id;  
108    $node->status = 1;    $node->status = 1;
109    node_save($node);    node_save($node);
110    variable_set('hosting_default_platform', $node->nid);    variable_set('hosting_default_platform', $node->nid);
111    variable_set('hosting_own_platform', $node->nid);    variable_set('hosting_own_platform', $node->nid);
112    
113    
114      $instance = new stdClass();
115      $instance->rid = $node->nid;
116      $instance->version = VERSION;
117      $instance->schema_version = drupal_get_installed_schema_version('system');
118      $instance->package_id = $package_id;
119      $instance->status = 0;
120      hosting_package_instance_save($instance);
121    
122    
123    #initial configuration of hostmaster - todo    #initial configuration of hostmaster - todo
124    variable_set('site_name', t('Hostmaster'));    variable_set('site_name', t('Hostmaster'));
125    variable_set('site_frontpage', 'hosting/sites');    variable_set('site_frontpage', 'hosting/sites');

Legend:
Removed from v.1.33  
changed lines
  Added in v.1.34

  ViewVC Help
Powered by ViewVC 1.1.2