Commit be00a61f authored by anarcat's avatar anarcat Committed by anarcat
Browse files

move ssl files to toplevel

parent 4fca5bb7
......@@ -11,7 +11,7 @@
*
* Add SSL configuration to the virtual host and create redirection if
* necessary (if the ssl_redirect option is set). This all takes
* effect only if the site_port is 443.
* effect only if the ssl option is on
*
* The configuration we add to the virtual host are those two simple
* lines:
......@@ -20,7 +20,7 @@
* SSLEngine On
*/
function provision_ssl_provision_apache_vhost_config($url, $options) {
if ($options['site_port'] == 443) {
if ($options['ssl']) {
if ($options['ssl_redirect'] && provision_path('exists', drush_get_option('vhost_path') . '/' . $url . '_80', FALSE, NULL, t("The redirection port is not available, no redirction installed"))) {
$newoptions = $options;
$newoptions['site_port'] = 80;
......@@ -38,7 +38,7 @@ function provision_ssl_provision_apache_vhost_config($url, $options) {
* This will delete the redirection vhost if it was created.
*/
function provision_ssl_provision_apache_delete_vhost($url, $options) {
if ($options['site_port'] == 443 && $options['ssl_redirect']) {
if ($options['ssl'] && $options['ssl_redirect']) {
provision_path('unlink', drush_get_option('vhost_path') . '/' . $url . '_80', TRUE, NULL, t("Failed deleting redirection vhost."));
}
}
<?php
// $Id$
function drush_provision_ssl_post_provision_verify($url = NULL) {
if (PROVISION_CONTEXT_SITE) {
drush_set_option('ssl', drush_get_option('ssl'), 'site');
}
}
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