Hi everyone,

I've figure out the source of the problem... it's when you run Galaxy in daemon mode (sh run.sh --daemon) it does not inherit and erases the $PATH of the system user running the process.  When I run Galaxy in a terminal (sh run.sh) I have no problems.

Is there a way to tell Galaxy in daemon mode to keep the $PATH of the user running the process?

best,
Leandro


On Tue, Jul 13, 2010 at 7:34 PM, Nate Coraor <nate@bx.psu.edu> wrote:
Leandro Hermida wrote:
Hi there,

I always use #!/usr/bin/env perl in my scripts, though in the case of using interpreter="..." it wouldn't look at the shebang since the command is specified at the command line.
I even tried without interpreter="..." just using <command>./my_script.pl <http://my_script.pl> ...</command> so that it would invoke shebang and I get this error:

/bin/sh: ./my_script.pl <http://my_script.pl>: No such file or directory

Hi Leandro,

In that case, you wouldn't want to include the './'.  The full path to the script is always prepended when executing the command.  When using 'interpreter', the value within is prepended to the the full path to the script.

--nate




On Tue, Jul 13, 2010 at 7:06 PM, John Brunelle <john_brunelle@harvard.edu <mailto:john_brunelle@harvard.edu>> wrote:

   Hi Leandro,

   A lot of tools that are perl or python scripts will have the shebang
   line hardcoded to the system version, e.g.:

   #!/usr/bin/perl

   If you change that to:

   #!/usr/bin/env perl

   it'll pick up the version in your path.  For example, we had to do
   this with tophat (python).

   However, that only applies to scripts that are run directly -- I'm
   not sure how Galaxy tool configs and the interpreter parameter work.

   Best,

   John


   On Tue, 13 Jul 2010, Leandro Hermida wrote:

       Dear all,

       Sorry if I missed it, I looked in the list archives and couldn't
       find any mention of the topic.

       I am developing tools for Galaxy and thus running a Galaxy
       server from my within my home directory under my username. I
       have my own Perl
       installed in my home directory and this is in my $PATH, I don't
       use the system Perl, but when I run a Galaxy tool with <command
       interpreter="perl"> it is using the system Perl, as if my $PATH
       is not used at all.  Since the Galaxy server and tool runner is
       running
       under my username and it looks like it just forks off a call to
       "perl ...." when it forks why doesn't it use my Perl?

       best,
       Leandro




------------------------------------------------------------------------

_______________________________________________
galaxy-dev mailing list
galaxy-dev@lists.bx.psu.edu