Marius Cramer
2014-02-10 738c3d47f74d8a117175452aac2cd662b0e3b95b
install/dist/lib/gentoo.lib.php
@@ -332,13 +332,24 @@
         caselog($command.' &> /dev/null', __FILE__, __LINE__, "EXECUTED: $command", "Failed to execute the command $command");
      }
      //* Append the configuration for amavisd to the master.cf file
        // Append the configuration for amavisd to the master.cf file
      $content = rf($conf['postfix']['config_dir'].'/master.cf');
      if(!stristr($content, '127.0.0.1:10025')) //* Only add the content if we had not addded it before
         {
      // Only add the content if we had not addded it before
      if(!preg_match('/^amavis\s+unix\s+/m', $content)) {
         unset($content);
         $content = $this->get_template_file('master_cf_amavis', true);
         af($conf['postfix']['config_dir'].'/master.cf', $content);
         $content = rf($conf['postfix']['config_dir'].'/master.cf');
      }
      if(!preg_match('/^127.0.0.1:10025\s+/m', $content)) {
          unset($content);
            $content = $this->get_template_file('master_cf_amavis10025', true);
         af($conf['postfix']['config_dir'].'/master.cf', $content);
         $content = rf($conf['postfix']['config_dir'].'/master.cf');
      }
      if(!preg_match('/^127.0.0.1:10027\s+/m', $content)) {
         unset($content);
         $content = $this->get_template_file('master_cf_amavis10027', true);
         af($conf['postfix']['config_dir'].'/master.cf', $content);
      }
      unset($content);
@@ -1003,19 +1014,19 @@
      }
      //* Install the update script
      if (is_file('/usr/local/bin/ispconfig_update_from_svn.sh')) {
         unlink('/usr/local/bin/ispconfig_update_from_svn.sh');
      if (is_file('/usr/local/bin/ispconfig_update_from_dev.sh')) {
         unlink('/usr/local/bin/ispconfig_update_from_dev.sh');
      }
      chown($install_dir.'/server/scripts/update_from_svn.sh', 'root');
      chmod($install_dir.'/server/scripts/update_from_svn.sh', 0700);
      chown($install_dir.'/server/scripts/update_from_dev.sh', 'root');
      chmod($install_dir.'/server/scripts/update_from_dev.sh', 0700);
      chown($install_dir.'/server/scripts/update_from_tgz.sh', 'root');
      chmod($install_dir.'/server/scripts/update_from_tgz.sh', 0700);
      chown($install_dir.'/server/scripts/ispconfig_update.sh', 'root');
      chmod($install_dir.'/server/scripts/ispconfig_update.sh', 0700);
      if (!is_link('/usr/local/bin/ispconfig_update_from_svn.sh')) {
         symlink($install_dir.'/server/scripts/ispconfig_update.sh', '/usr/local/bin/ispconfig_update_from_svn.sh');
      if (!is_link('/usr/local/bin/ispconfig_update_from_dev.sh')) {
         symlink($install_dir.'/server/scripts/ispconfig_update.sh', '/usr/local/bin/ispconfig_update_from_dev.sh');
      }
      if (!is_link('/usr/local/bin/ispconfig_update.sh')) {