Skip to content

Commit ae10cf9

Browse files
committed
- Changed suse install code and fixed a bug in server.php
1 parent a21c725 commit ae10cf9

File tree

2 files changed

+12
-4
lines changed

2 files changed

+12
-4
lines changed

install/dist/lib/opensuse.lib.php

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -710,6 +710,15 @@ public function install_ispconfig()
710710
if(!@is_link("$vhost_conf_enabled_dir/000-ispconfig.vhost")) {
711711
exec("ln -s $vhost_conf_dir/ispconfig.vhost $vhost_conf_enabled_dir/000-ispconfig.vhost");
712712
}
713+
714+
exec('mkdir -p /srv/www/php-fcgi-scripts/ispconfig');
715+
exec('cp tpl/apache_ispconfig_fcgi_starter.master /srv/www/php-fcgi-scripts/ispconfig/.php-fcgi-starter');
716+
exec('chmod +x /srv/www/php-fcgi-scripts/ispconfig/.php-fcgi-starter');
717+
exec('ln -s /usr/local/ispconfig/interface/web /srv/www/ispconfig');
718+
exec('chown -R ispconfig:ispconfig /srv/www/php-fcgi-scripts/ispconfig');
719+
720+
//replaceLine('/var/www/php-fcgi-scripts/ispconfig/.php-fcgi-starter','PHPRC=','PHPRC=/etc/',0,0);
721+
713722
}
714723

715724
// Make the Clamav log files readable by ISPConfig
@@ -722,7 +731,7 @@ public function install_ispconfig()
722731
exec('chmod 700 /usr/local/bin/ispconfig_update_from_svn.sh');
723732

724733
//set the fast cgi starter script to executable
725-
exec('chmod 755 '.$install_dir.'/interface/bin/php-fcgi');
734+
//exec('chmod 755 '.$install_dir.'/interface/bin/php-fcgi');
726735

727736
//* Make the logs readable for the ispconfig user
728737
if(@is_file('/var/log/mail.log')) exec('chmod +r /var/log/mail.log');

server/server.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -70,9 +70,8 @@
7070
if($app->dbmaster->connect()) {
7171

7272
// get the dalaog_id of the last performed record
73-
$tmp_rec = $app->dbmaster->queryOneRecord("SELECT updated FROM server WHERE server_id = ".$conf["server_id"]);
74-
$conf['last_datalog_id'] = (int)$tmp_rec['updated'];
75-
unset($tmp_rec);
73+
$server_db_record = $app->dbmaster->queryOneRecord("SELECT updated, config FROM server WHERE server_id = ".$conf["server_id"]);
74+
$conf['last_datalog_id'] = (int)$server_db_record['updated'];
7675

7776
// Check if there is anything to update
7877
$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)");

0 commit comments

Comments
 (0)