Fixing AIRAVATA-1742
Project: http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/repo Commit: http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/commit/914011b1 Tree: http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/tree/914011b1 Diff: http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/diff/914011b1 Branch: refs/heads/master Commit: 914011b1a0eca5f720fdd7266543ac046559dec4 Parents: 47f9f0f Author: Supun Nakandala <[email protected]> Authored: Wed Jul 1 02:00:09 2015 +0530 Committer: Supun Nakandala <[email protected]> Committed: Wed Jul 1 02:09:59 2015 +0530 ---------------------------------------------------------------------- app/libraries/ExperimentUtilities.php | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/blob/914011b1/app/libraries/ExperimentUtilities.php ---------------------------------------------------------------------- diff --git a/app/libraries/ExperimentUtilities.php b/app/libraries/ExperimentUtilities.php index e3de925..83d849d 100644 --- a/app/libraries/ExperimentUtilities.php +++ b/app/libraries/ExperimentUtilities.php @@ -18,6 +18,8 @@ class ExperimentUtilities { private static $experimentPath; + private static $sshUser = "root"; + /** * Launch the experiment with the given ID * @param $expId @@ -160,9 +162,8 @@ class ExperimentUtilities } $advHandling = new AdvancedOutputDataHandling(); - $sshUser = "root"; $hostName = $_SERVER['SERVER_NAME']; - $expPathConstant = 'file://' . $sshUser . '@' . $hostName . ':' . Config::get('pga_config.airavata')['experiment-data-absolute-path']; + $expPathConstant = 'file://' . ExperimentUtilities::$sshUser . '@' . $hostName . ':' . Config::get('pga_config.airavata')['experiment-data-absolute-path']; $advHandling->outputDataDir = str_replace(Config::get('pga_config.airavata')['experiment-data-absolute-path'], $expPathConstant, ExperimentUtilities::$experimentPath); @@ -288,8 +289,8 @@ class ExperimentUtilities Please try again later or report a bug using the link in the Help menu.</p>'); $experimentAssemblySuccessful = false; } - - $experimentInput->value = Config::get('pga_config.airavata')['experiment-data-absolute-path']; + $hostName = $_SERVER['SERVER_NAME']; + $experimentInput->value = 'file://' . ExperimentUtilities::$sshUser . '@' . $hostName . ':' . $filePath; $experimentInput->type = $applicationInput->type; } else {
