Преглед на файлове

cambie el directorio antes de ejecutar el task

Luciano Andrade преди 7 години
родител
ревизия
396a64f846
променени са 1 файла, в които са добавени 4 реда и са изтрити 0 реда
  1. 4 0
      Services/TaskLoggerService.php

+ 4 - 0
Services/TaskLoggerService.php

@@ -91,8 +91,12 @@ class TaskLoggerService implements ConsumerInterface
      */
     public function runProcess($filename)
     {
+	$predir = getcwd();
+	chdir(dirname($filename));
         $process = new Process($filename);
         $process->run();
+	chdir($predir);
+	
 
         return array(
             'output' => $process->getOutput(),