From 07186889432baaf09c7162b4528bb5c7c0e140e9 Mon Sep 17 00:00:00 2001 From: Jarrett Jordaan Date: Fri, 6 Nov 2009 11:55:56 +0200 Subject: [PATCH] KTS-4494: Updated config_settings table to add python location --- setup/wizard/steps/database.php | 27 +++++++++++++++------------ setup/wizard/templates/complete.tpl | 1 + 2 files changed, 16 insertions(+), 12 deletions(-) diff --git a/setup/wizard/steps/database.php b/setup/wizard/steps/database.php index c3f3a27..f4d2a9c 100644 --- a/setup/wizard/steps/database.php +++ b/setup/wizard/steps/database.php @@ -776,17 +776,6 @@ class database extends Step } private function writeBinaries() { - $services = $this->util->getDataFromSession('services'); - $binaries = $services['binaries']; - if($binaries) { - foreach ($binaries as $k=>$bin) { - if($k != 1) { - $updateBin = 'UPDATE config_settings c SET c.value = "'.str_replace('\\', '\\\\', $bin).'" where c.group_name = "externalBinary" and c.display_name = "'.$k.'";'; - $this->util->dbUtilities->query($updateBin); - } - } - } - // if Windows, attempt to insert full paths to binaries if (WINDOWS_OS) { $winBinaries = array('php' => 'ZendServer\bin\php.exe', 'python' => 'openoffice\program\python.exe', @@ -822,7 +811,21 @@ class database extends Step // if Linux? else { // TODO python binary? - // TODO other binaries? + // Python + $services = $this->util->getDataFromSession('services'); + $binaries = $services['binaries']; + $python = "/usr/bin/python"; + if(file_exists($python)) { + $binaries['python'] = $python; + } + if($binaries) { + foreach ($binaries as $k=>$bin) { + if($k != 1) { + $updateBin = 'UPDATE config_settings c SET c.value = "'.str_replace('\\', '\\\\', $bin).'" where c.group_name = "externalBinary" and c.display_name = "'.$k.'";'; + $this->util->dbUtilities->query($updateBin); + } + } + } } } diff --git a/setup/wizard/templates/complete.tpl b/setup/wizard/templates/complete.tpl index 8dd18cf..66e5175 100644 --- a/setup/wizard/templates/complete.tpl +++ b/setup/wizard/templates/complete.tpl @@ -25,6 +25,7 @@

cd KnowledgeTree_Installation_Folder
+ dmsctl.bat install dmsctl.bat start cd /usr/share/knowledgetree-ce
-- libgit2 0.21.4