Commit 676734c3 authored by mig5's avatar mig5 Committed by mig5
Browse files

fix up some more hostmaster-install stuff. properly find the apache2ctl...

fix up some more hostmaster-install stuff. properly find the apache2ctl restart command and save it to the .drushrc.php
parent aa300de0
...@@ -24,7 +24,7 @@ function drush_http_post_provision_verify($url = null) { ...@@ -24,7 +24,7 @@ function drush_http_post_provision_verify($url = null) {
drush_set_option('web_port', drush_get_option('web_port', 80), 'user'); drush_set_option('web_port', drush_get_option('web_port', 80), 'user');
drush_set_option('web_group', drush_get_option('web_group'), 'user'); drush_set_option('web_group', drush_get_option('web_group'), 'user');
drush_set_option('script_user', drush_get_option('script_user'), 'user'); drush_set_option('script_user', drush_get_option('script_user'), 'user');
drush_set_option('restart_cmd', drush_get_option('restart_cmd'), 'user'); drush_set_option('restart_cmd', drush_get_option('restart_cmd', _provision_default_restart_cmd(), 'user'), 'user');
drush_set_option('backup_path', drush_get_option('backup_path'), 'user'); drush_set_option('backup_path', drush_get_option('backup_path'), 'user');
drush_set_option('config_path', drush_get_option('config_path'), 'user'); drush_set_option('config_path', drush_get_option('config_path'), 'user');
} }
......
<?php <?php
/** /**
* @file manual site migrate system * @file install the hostmaster system
*/ */
function drush_provision_hostmaster_install($site, $platform, $client_email) { function drush_provision_hostmaster_install($site, $platform, $client_email) {
$data = drush_get_merged_options();
$data['publish_path'] = $data['r'] = $data['root'] = realpath($platform);
$data['provision_context'] = "server";
$data['init_http'] = "apache";
$data['restart_cmd'] = _provision_default_restart_cmd();
$data['web_port'] = drush_get_option('web_port', 80);
// Server verify
drush_backend_invoke('provision-verify', $data);
// verify the current platform // verify the current platform
drush_backend_invoke('provision-verify', array( drush_backend_invoke('provision-verify', array(
...@@ -21,10 +12,10 @@ function drush_provision_hostmaster_install($site, $platform, $client_email) { ...@@ -21,10 +12,10 @@ function drush_provision_hostmaster_install($site, $platform, $client_email) {
'provision_context' => "platform", 'provision_context' => "platform",
'publish_path' => drush_locate_root(drush_get_option(array('r', 'root'), NULL)), 'publish_path' => drush_locate_root(drush_get_option(array('r', 'root'), NULL)),
'platform' => '5') // dirty hardcoded to create the first platform apache config 'platform' => '5') // dirty hardcoded to create the first platform apache config
// this will become unnecessary when we have drush // this will become unnecessary when we have drush aliases
); );
// verify the site prior to migration // install the hostmaster site
drush_backend_invoke('provision-install', array( drush_backend_invoke('provision-install', array(
$site, $site,
'uri' => $site, 'uri' => $site,
...@@ -32,7 +23,7 @@ function drush_provision_hostmaster_install($site, $platform, $client_email) { ...@@ -32,7 +23,7 @@ function drush_provision_hostmaster_install($site, $platform, $client_email) {
'profile' => "hostmaster", 'profile' => "hostmaster",
'provision_context' => "site", 'provision_context' => "site",
'client_email' => $client_email, 'client_email' => $client_email,
'port' => drush_get_option('web_port', 80)) 'site_port' => drush_get_option('web_port', 80))
); );
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment