diff --git a/http/apache/apache_service.inc b/http/apache/apache_service.inc index ab5858835725eb8652a62ef598608f495450e436..31949b12d9818ed97d3b11188f4a041d833e1176 100644 --- a/http/apache/apache_service.inc +++ b/http/apache/apache_service.inc @@ -143,7 +143,7 @@ class provisionConfig_apache_site extends provisionConfig_apache { $this->data['site_port'] = 80; } - return $this->data['vhost_path'] . '/' . $this->data['site_url'] . '_' . $this->data['site_port']; + return $this->data['vhost_path'] . '/' . $this->data['uri'] . '_' . $this->data['site_port']; } function process() { @@ -152,7 +152,7 @@ class provisionConfig_apache_site extends provisionConfig_apache { } $this->data['extra_config'] = "# Extra configuration from modules:\n"; - $this->data['extra_config'] .= join("\n", drush_command_invoke_all('provision_apache_vhost_config', $this->data['site_url'], $this->data)); + $this->data['extra_config'] .= join("\n", drush_command_invoke_all('provision_apache_vhost_config', $this->data['uri'], $this->data)); } } diff --git a/http/apache/vhost.tpl.php b/http/apache/vhost.tpl.php index 90cd84ea74d8f07ccc462112ebb2c68711c62103..b08a7a8a81b07a636c516c360e7d03320f432b20 100644 --- a/http/apache/vhost.tpl.php +++ b/http/apache/vhost.tpl.php @@ -4,7 +4,7 @@ <?php endif;?> DocumentRoot <?php print $this->platform->root; ?> - ServerName <?php print $site_url; ?> + ServerName <?php print $uri; ?> SetEnv db_type <?php print urlencode($db_type); ?> @@ -29,7 +29,7 @@ <?php print $extra_config; ?> # Error handler for Drupal > 4.6.7 - <Directory "<?php print $this->platform->root; ?>/sites/<?php print trim($site_url, '/'); ?>/files"> + <Directory "<?php print $this->platform->root; ?>/sites/<?php print $uri; ?>/files"> SetHandler This_is_a_Drupal_security_line_do_not_remove </Directory> diff --git a/http/apache/vhost_disabled.tpl.php b/http/apache/vhost_disabled.tpl.php index 2b63f4e07e2bbadd8efde7cbed81c0199b836030..6f951eac4653f4ca14834247b2aef9cf2bec7ed9 100644 --- a/http/apache/vhost_disabled.tpl.php +++ b/http/apache/vhost_disabled.tpl.php @@ -4,7 +4,7 @@ <?php endif;?> DocumentRoot <?php print $this->platform->root; ?> - ServerName <?php print $site_url; ?> + ServerName <?php print $uri; ?> <?php if (is_array($aliases)) : foreach ($aliases as $alias) : ?> @@ -15,6 +15,6 @@ RewriteEngine on # the ? at the end is to remove any query string in the original url - RewriteRule ^(.*)$ <?php print $redirect_url . '/' . $site_url ?>? + RewriteRule ^(.*)$ <?php print $redirect_url . '/' . $uri ?>? </VirtualHost> diff --git a/http/apache/vhost_redirect.tpl.php b/http/apache/vhost_redirect.tpl.php index 47b7bf007aac1e17441653412564c8655e7d815c..4040bc51085b6cdadf5807b4f7150355c1cbf372 100644 --- a/http/apache/vhost_redirect.tpl.php +++ b/http/apache/vhost_redirect.tpl.php @@ -12,12 +12,12 @@ <?php else: # this should never happen and has the potential of creating an infinite redirection loop ?> - ServerName <?php print $site_url ?> + ServerName <?php print $uri ?> <?php endif; ?> <?php if ($ssl_redirect): ?> - RedirectMatch permanent ^(.*) https://<?php print $site_url ?>$1 + RedirectMatch permanent ^(.*) https://<?php print $uri ?>$1 <?php else: ?> - RedirectMatch permanent ^(.*) http://<?php print $site_url ?>$1 + RedirectMatch permanent ^(.*) http://<?php print $uri ?>$1 <?php endif; ?> </VirtualHost> diff --git a/platform/deploy.provision.inc b/platform/deploy.provision.inc index 2c7abc6b53602e6884a145ad34ec72186b571f54..f0af359c7f37eba98d2b2deffb247f78b122b2cf 100644 --- a/platform/deploy.provision.inc +++ b/platform/deploy.provision.inc @@ -35,7 +35,6 @@ function drush_provision_drupal_provision_deploy_validate($backup_file = null) { */ function drush_provision_drupal_pre_provision_deploy($backup_file) { // the url is likely to have changed in the deployment - drush_set_option('site_url', drush_get_option('uri')); $extracted = provision_service('file')->extract(drush_get_option('backup_file'), d()->root . '/sites/' . d()->uri) ->succeed('Successfully extracted the contents of @path') ->fail('Failed to extract the contents of @path', 'PROVISION_BACKUP_EXTRACTION_FAILED') @@ -80,7 +79,7 @@ function drush_provision_drupal_pre_provision_deploy_rollback() { } function drush_provision_drupal_provision_deploy() { - _provision_drupal_maintain_aliases(drush_get_option('site_url')); + _provision_drupal_maintain_aliases(d()->uri); } diff --git a/platform/drupal/deploy.inc b/platform/drupal/deploy.inc index 185fed0ef2cbd2c01a903c0aa7320fc89374dd53..6cef13c195f6ee95a7a9885227bf0d565f7b47f6 100644 --- a/platform/drupal/deploy.inc +++ b/platform/drupal/deploy.inc @@ -1,8 +1,8 @@ <?php // $Id$ -$new_url = drush_get_option('site_url'); -$old_url = drush_get_option('site_url', '', 'site'); +$new_url = drush_get_option('uri'); +$old_url = drush_get_option('uri', '', 'site'); /** * @file diff --git a/platform/drupal/deploy_7.inc b/platform/drupal/deploy_7.inc index 63faebc9857254ce3b0df0278298c1b51ebeb320..8de6cc3c153c5f05ac889612bb667443b33cd0c8 100644 --- a/platform/drupal/deploy_7.inc +++ b/platform/drupal/deploy_7.inc @@ -1,8 +1,8 @@ <?php // $Id$ -$new_url = drush_get_option('site_url'); -$old_url = drush_get_option('site_url', 'site'); +$new_url = drush_get_option('uri'); +$old_url = drush_get_option('uri', 'site'); /** * @file diff --git a/platform/drupal/install_5.inc b/platform/drupal/install_5.inc index 5c17c9e278bf364b3a31d312f2d6693a536eb868..47fabae0f6672842ec2ffdca74e499873fdce5a9 100644 --- a/platform/drupal/install_5.inc +++ b/platform/drupal/install_5.inc @@ -4,7 +4,7 @@ * Rebuild all the caches */ -$GLOBALS['url'] = drush_get_option('site_url'); +$GLOBALS['url'] = drush_get_option('uri'); $GLOBALS['profile'] = drush_get_option('profile'); $GLOBALS['install_locale'] = drush_get_option('language'); $GLOBALS['client_email'] = drush_get_option('client_email'); diff --git a/platform/drupal/install_6.inc b/platform/drupal/install_6.inc index 967613e5e4f3c3b84549140176e8fce985bab9b4..dd836b6159cd23b7e8bcdeeb7d8d0e5ab55b1d3c 100644 --- a/platform/drupal/install_6.inc +++ b/platform/drupal/install_6.inc @@ -4,7 +4,7 @@ * Rebuild all the caches */ -$GLOBALS['url'] = drush_get_option('site_url'); +$GLOBALS['url'] = drush_get_option('uri'); $GLOBALS['profile'] = drush_get_option('profile'); $GLOBALS['install_locale'] = drush_get_option('language'); $GLOBALS['client_email'] = drush_get_option('client_email'); diff --git a/platform/drupal/install_7.inc b/platform/drupal/install_7.inc index a72248c5546717d3bed0b8dd8fdbf0ad42905755..633edc53ad8f26a0f6414251edb705f55488c316 100644 --- a/platform/drupal/install_7.inc +++ b/platform/drupal/install_7.inc @@ -4,7 +4,7 @@ * Rebuild all the caches */ -$GLOBALS['url'] = drush_get_option('site_url'); +$GLOBALS['url'] = drush_get_option('uri'); $GLOBALS['profile'] = drush_get_option('profile'); $GLOBALS['install_locale'] = drush_get_option('language'); $GLOBALS['client_email'] = drush_get_option('client_email'); diff --git a/platform/provision_drupal.drush.inc b/platform/provision_drupal.drush.inc index 4ce1ea8dd04d53f4ae23efef2215ab6e4ed0f6da..9b5c6b06237375a8d30471a5d6171a08054b1eca 100644 --- a/platform/provision_drupal.drush.inc +++ b/platform/provision_drupal.drush.inc @@ -74,7 +74,6 @@ function _provision_context_init() { // i don't think i should be bootstrapping here yet ... but i have no choice yet. drush_bootstrap(DRUSH_BOOTSTRAP_DRUPAL_ROOT); if ($context === 'site') { - drush_set_default('site_url', drush_get_option('uri')); drush_set_default('profile', 'default'); drush_set_default('language', 'en'); drush_set_default('aliases', array()); @@ -104,7 +103,6 @@ function provision_drupal_drush_exit() { if (preg_match("/^provision-/", $command[0])) { if (PROVISION_CONTEXT_SITE) { if (drush_get_option('installed')) { - drush_set_option('site_url', drush_get_option('site_url'), 'site'); drush_set_option('site_id', drush_get_option('site_id'), 'site'); drush_set_option('client_email', drush_get_option('client_email'), 'site'); provision_save_site_data(); @@ -215,7 +213,7 @@ class provisionConfig_drupal_settings extends provisionConfig { } $this->data['extra_config'] = "# Extra configuration from modules:\n"; - $this->data['extra_config'] .= join("\n", drush_command_invoke_all('provision_drupal_config', $this->data['site_url'], $this->data)); + $this->data['extra_config'] .= join("\n", drush_command_invoke_all('provision_drupal_config', $this->data['uri'], $this->data)); $this->group = drush_get_option('web_group'); } diff --git a/platform/provision_drupal_settings.tpl.php b/platform/provision_drupal_settings.tpl.php index 8122b0938e4c8d13cc72f20bf6c7fac89dd91085..4967ea040fc04a5a4aa9cc94b78e9dfe623e8b24 100644 --- a/platform/provision_drupal_settings.tpl.php +++ b/platform/provision_drupal_settings.tpl.php @@ -54,8 +54,8 @@ global $conf; $conf['install_profile'] = '<?php print $profile ?>'; - $conf['file_directory_path'] = 'sites/<?php print $site_url ?>/files'; - $conf['file_directory_temp'] = 'sites/<?php print $site_url ?>/files/tmp'; + $conf['file_directory_path'] = 'sites/<?php print $uri ?>/files'; + $conf['file_directory_temp'] = 'sites/<?php print $uri ?>/files/tmp'; $conf['file_downloads'] = 1; $conf['cache'] = 1; $conf['clean_url'] = 1; diff --git a/provision.environment.inc b/provision.environment.inc index d9c327a9d44dee8f58388dc8d5f0c75d81c2d050..c2919790c1c2f1a0a5bb2c86f399ced4b633163c 100644 --- a/provision.environment.inc +++ b/provision.environment.inc @@ -286,7 +286,7 @@ class provisionServer extends provisionEnvironment { class provisionPlatform extends provisionEnvironment { static function option_documentation() { return array( - '--root' => 'platform: path to a drupal installation', + '--root' => 'platform: path to a Drupal installation', '--server' => 'drush backend server; default @server_localhost', '--web_server' => 'web server hosting the platform; default @server_localhost', ); @@ -331,7 +331,6 @@ class provisionSite extends provisionEnvironment { $this->root = $this->platform->root; $this->setProperty('uri'); - $this->setProperty('site_url', str_replace(array('https://', 'http://'), '', $this->uri)); $this->setProperty('language', 'en'); $this->setProperty('aliases', array()); $this->setProperty('site_port', 80); @@ -349,7 +348,7 @@ class provisionSite extends provisionEnvironment { $this->aliases = array(); } - // this can potentially be handled by a drupal sub class + // this can potentially be handled by a Drupal sub class $this->setProperty('profile', 'default'); } diff --git a/ssl/provision_ssl.drush.inc b/ssl/provision_ssl.drush.inc index 5e8914b9c7eaedf4fad9ad26e93588b0ebf17e51..75c979feac1a4ba419366ea28af6fcb13b668136 100644 --- a/ssl/provision_ssl.drush.inc +++ b/ssl/provision_ssl.drush.inc @@ -41,11 +41,11 @@ class provisionConfig_ssl_vhost extends provisionConfig { public $description = 'Redirect for SSL'; function filename() { - return $this->data['vhost_path'] . '/' . $this->data['site_url'] . '_80'; + return $this->data['vhost_path'] . '/' . $this->data['uri'] . '_80'; } function process() { - array_push($this->data['aliases'], $this->data['site_url']); + array_push($this->data['aliases'], $this->data['uri']); $this->data['site_port'] = 80; } }