You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airavata.apache.org by sm...@apache.org on 2015/07/14 18:38:37 UTC

[32/40] airavata-php-gateway git commit: Fixing AIRAVATA-1742

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/6af78dc9
Tree: http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/tree/6af78dc9
Diff: http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/diff/6af78dc9

Branch: refs/heads/0.15-release-branch
Commit: 6af78dc9bdaac122a0e9fd9843ada9f25f47b5e3
Parents: b9e88f7
Author: Supun Nakandala <sc...@apache.org>
Authored: Wed Jul 1 02:00:09 2015 +0530
Committer: Supun Nakandala <sc...@apache.org>
Committed: Wed Jul 1 02:00:09 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/6af78dc9/app/libraries/ExperimentUtilities.php
----------------------------------------------------------------------
diff --git a/app/libraries/ExperimentUtilities.php b/app/libraries/ExperimentUtilities.php
index f5a9c03..52a06f7 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 {