From ae10cf9d440960cd6be6404d307df7bb1cca6abc Mon Sep 17 00:00:00 2001
From: tbrehm <t.brehm@ispconfig.org>
Date: Thu, 05 Mar 2009 16:10:48 -0500
Subject: [PATCH] - Changed suse install code and fixed a bug in server.php
---
install/dist/lib/opensuse.lib.php | 11 ++++++++++-
server/server.php | 5 ++---
2 files changed, 12 insertions(+), 4 deletions(-)
diff --git a/install/dist/lib/opensuse.lib.php b/install/dist/lib/opensuse.lib.php
index 7795df3..65f60c9 100644
--- a/install/dist/lib/opensuse.lib.php
+++ b/install/dist/lib/opensuse.lib.php
@@ -710,6 +710,15 @@
if(!@is_link("$vhost_conf_enabled_dir/000-ispconfig.vhost")) {
exec("ln -s $vhost_conf_dir/ispconfig.vhost $vhost_conf_enabled_dir/000-ispconfig.vhost");
}
+
+ exec('mkdir -p /srv/www/php-fcgi-scripts/ispconfig');
+ exec('cp tpl/apache_ispconfig_fcgi_starter.master /srv/www/php-fcgi-scripts/ispconfig/.php-fcgi-starter');
+ exec('chmod +x /srv/www/php-fcgi-scripts/ispconfig/.php-fcgi-starter');
+ exec('ln -s /usr/local/ispconfig/interface/web /srv/www/ispconfig');
+ exec('chown -R ispconfig:ispconfig /srv/www/php-fcgi-scripts/ispconfig');
+
+ //replaceLine('/var/www/php-fcgi-scripts/ispconfig/.php-fcgi-starter','PHPRC=','PHPRC=/etc/',0,0);
+
}
// Make the Clamav log files readable by ISPConfig
@@ -722,7 +731,7 @@
exec('chmod 700 /usr/local/bin/ispconfig_update_from_svn.sh');
//set the fast cgi starter script to executable
- exec('chmod 755 '.$install_dir.'/interface/bin/php-fcgi');
+ //exec('chmod 755 '.$install_dir.'/interface/bin/php-fcgi');
//* Make the logs readable for the ispconfig user
if(@is_file('/var/log/mail.log')) exec('chmod +r /var/log/mail.log');
diff --git a/server/server.php b/server/server.php
index e11e038..7837ca8 100644
--- a/server/server.php
+++ b/server/server.php
@@ -70,9 +70,8 @@
if($app->dbmaster->connect()) {
// get the dalaog_id of the last performed record
- $tmp_rec = $app->dbmaster->queryOneRecord("SELECT updated FROM server WHERE server_id = ".$conf["server_id"]);
- $conf['last_datalog_id'] = (int)$tmp_rec['updated'];
- unset($tmp_rec);
+ $server_db_record = $app->dbmaster->queryOneRecord("SELECT updated, config FROM server WHERE server_id = ".$conf["server_id"]);
+ $conf['last_datalog_id'] = (int)$server_db_record['updated'];
// Check if there is anything to update
$tmp_rec = $app->dbmaster->queryOneRecord("SELECT count(server_id) as number from sys_datalog WHERE datalog_id > ".$conf['last_datalog_id']." AND (server_id = ".$conf["server_id"]." OR server_id = 0)");
--
Gitblit v1.9.1