You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by be...@apache.org on 2011/06/05 10:51:46 UTC

svn commit: r1132154 - /incubator/mesos/trunk/frameworks/mesos-submit/mesos_submit.py

Author: benh
Date: Sun Jun  5 08:51:45 2011
New Revision: 1132154

URL: http://svn.apache.org/viewvc?rev=1132154&view=rev
Log:
Find executor relative to location of mesos_submit.py instead of
relative to local directory when running mesos-submit.

Modified:
    incubator/mesos/trunk/frameworks/mesos-submit/mesos_submit.py

Modified: incubator/mesos/trunk/frameworks/mesos-submit/mesos_submit.py
URL: http://svn.apache.org/viewvc/incubator/mesos/trunk/frameworks/mesos-submit/mesos_submit.py?rev=1132154&r1=1132153&r2=1132154&view=diff
==============================================================================
--- incubator/mesos/trunk/frameworks/mesos-submit/mesos_submit.py (original)
+++ incubator/mesos/trunk/frameworks/mesos-submit/mesos_submit.py Sun Jun  5 08:51:45 2011
@@ -42,7 +42,8 @@ class SubmitScheduler(mesos.Scheduler):
     return self.framework_name
 
   def getExecutorInfo(self, driver):
-    executorPath = os.path.join(os.getcwd(), "executor")
+    frameworkDir = os.path.abspath(os.path.dirname(sys.argv[0]))
+    executorPath = os.path.join(frameworkDir, "executor")
     return mesos.ExecutorInfo(executorPath, "")
 
   def registered(self, driver, fid):