From 7e1cfbe9376c5cb82170b4166ef0677a1652718b Mon Sep 17 00:00:00 2001 From: ftimme <ft@falkotimme.com> Date: Thu, 03 May 2012 09:12:31 -0400 Subject: [PATCH] - Fixed FS#2198. --- install/lib/installer_base.lib.php | 30 ++++++++++++++---------------- 1 files changed, 14 insertions(+), 16 deletions(-) diff --git a/install/lib/installer_base.lib.php b/install/lib/installer_base.lib.php index bb88780..cbabdee 100644 --- a/install/lib/installer_base.lib.php +++ b/install/lib/installer_base.lib.php @@ -1420,7 +1420,7 @@ global $conf; //* Create the ispconfig apps vhost user and group - if($conf['apache']['installed'] == true){ + if($conf['apache']['installed'] == true && $this->install_ispconfig_interface == true){ $apps_vhost_user = escapeshellcmd($conf['web']['apps_vhost_user']); $apps_vhost_group = escapeshellcmd($conf['web']['apps_vhost_group']); $install_dir = escapeshellcmd($conf['web']['website_basedir'].'/apps'); @@ -1469,12 +1469,11 @@ //copy('tpl/apache_ispconfig.vhost.master', "$vhost_conf_dir/ispconfig.vhost"); //* and create the symlink - if($this->install_ispconfig_interface == true) { - if(@is_link($vhost_conf_enabled_dir.'/apps.vhost')) unlink($vhost_conf_enabled_dir.'/apps.vhost'); - if(!@is_link($vhost_conf_enabled_dir.'/000-apps.vhost')) { - symlink($vhost_conf_dir.'/apps.vhost',$vhost_conf_enabled_dir.'/000-apps.vhost'); - } + if(@is_link($vhost_conf_enabled_dir.'/apps.vhost')) unlink($vhost_conf_enabled_dir.'/apps.vhost'); + if(!@is_link($vhost_conf_enabled_dir.'/000-apps.vhost')) { + symlink($vhost_conf_dir.'/apps.vhost',$vhost_conf_enabled_dir.'/000-apps.vhost'); } + if(!is_file($conf['web']['website_basedir'].'/php-fcgi-scripts/apps/.php-fcgi-starter')) { mkdir($conf['web']['website_basedir'].'/php-fcgi-scripts/apps', 0755, true); copy('tpl/apache_apps_fcgi_starter.master',$conf['web']['website_basedir'].'/php-fcgi-scripts/apps/.php-fcgi-starter'); @@ -1483,7 +1482,7 @@ } } - if($conf['nginx']['installed'] == true){ + if($conf['nginx']['installed'] == true && $this->install_ispconfig_interface == true){ $apps_vhost_user = escapeshellcmd($conf['web']['apps_vhost_user']); $apps_vhost_group = escapeshellcmd($conf['web']['apps_vhost_group']); $install_dir = escapeshellcmd($conf['web']['website_basedir'].'/apps'); @@ -1548,12 +1547,11 @@ //copy('tpl/nginx_ispconfig.vhost.master', "$vhost_conf_dir/ispconfig.vhost"); //* and create the symlink - if($this->install_ispconfig_interface == true) { - if(@is_link($vhost_conf_enabled_dir.'/apps.vhost')) unlink($vhost_conf_enabled_dir.'/apps.vhost'); - if(!@is_link($vhost_conf_enabled_dir.'/000-apps.vhost')) { - symlink($vhost_conf_dir.'/apps.vhost',$vhost_conf_enabled_dir.'/000-apps.vhost'); - } + if(@is_link($vhost_conf_enabled_dir.'/apps.vhost')) unlink($vhost_conf_enabled_dir.'/apps.vhost'); + if(!@is_link($vhost_conf_enabled_dir.'/000-apps.vhost')) { + symlink($vhost_conf_dir.'/apps.vhost',$vhost_conf_enabled_dir.'/000-apps.vhost'); } + } } @@ -1815,7 +1813,7 @@ $command = "chmod +x $install_dir/server/scripts/*.sh"; caselog($command.' &> /dev/null', __FILE__, __LINE__, "EXECUTED: $command", "Failed to execute the command $command"); - if($conf['apache']['installed'] == true){ + if($conf['apache']['installed'] == true && $this->install_ispconfig_interface == true){ //* Copy the ISPConfig vhost for the controlpanel $vhost_conf_dir = $conf['apache']['vhost_conf_dir']; $vhost_conf_enabled_dir = $conf['apache']['vhost_conf_enabled_dir']; @@ -1841,7 +1839,7 @@ //copy('tpl/apache_ispconfig.vhost.master', $vhost_conf_dir.'/ispconfig.vhost'); //* and create the symlink - if($this->install_ispconfig_interface == true && $this->is_update == false) { + if($this->is_update == false) { if(@is_link($vhost_conf_enabled_dir.'/ispconfig.vhost')) unlink($vhost_conf_enabled_dir.'/ispconfig.vhost'); if(!@is_link($vhost_conf_enabled_dir.'/000-ispconfig.vhost')) { symlink($vhost_conf_dir.'/ispconfig.vhost',$vhost_conf_enabled_dir.'/000-ispconfig.vhost'); @@ -1857,7 +1855,7 @@ } } - if($conf['nginx']['installed'] == true){ + if($conf['nginx']['installed'] == true && $this->install_ispconfig_interface == true){ //* Copy the ISPConfig vhost for the controlpanel $vhost_conf_dir = $conf['nginx']['vhost_conf_dir']; $vhost_conf_enabled_dir = $conf['nginx']['vhost_conf_enabled_dir']; @@ -1900,7 +1898,7 @@ //copy('tpl/nginx_ispconfig.vhost.master', $vhost_conf_dir.'/ispconfig.vhost'); //* and create the symlink - if($this->install_ispconfig_interface == true && $this->is_update == false) { + if($this->is_update == false) { if(@is_link($vhost_conf_enabled_dir.'/ispconfig.vhost')) unlink($vhost_conf_enabled_dir.'/ispconfig.vhost'); if(!@is_link($vhost_conf_enabled_dir.'/000-ispconfig.vhost')) { symlink($vhost_conf_dir.'/ispconfig.vhost',$vhost_conf_enabled_dir.'/000-ispconfig.vhost'); -- Gitblit v1.9.1