On 14/02/11 17:45, Peter Cock wrote:
On Mon, Feb 14, 2011 at 7:17 AM, Florent Angly<florent.angly@gmail.com> wrote:
Hi Alex,
Thanks for the pointers! The fact that Galaxy only reads /etc/profile and not the profile of the user that runs it, ~/.profile, entirely explains why it cannot find Grinder or Velvet: I run Galaxy on a Mac OS X and I have many programs installed from MacPorts. All these programs get installed under /opt/local/bin/, which is outside of the usual Mac paths (to avoid any conflict). So, every user on this Mac has to have /opt/local/bin added to its path in its ~/.profile to be able to use MacPorts program. I did this for my galaxy user, but if Galaxy does not read ~/.profile, then it won't find the programs I installed.
I am surprised that you report that Galaxy does not read ~/.profile in fact, because on this wiki page, https://bitbucket.org/galaxy/galaxy-central/wiki/Config/ProductionServer, it is advised to set up the $TEMP environment variable for Galaxy. How is one supposed to do that? I don't think that it would be advisable to ask people to edit their system-wide /etc/profile...
So, how do I have to setup environment variables so that they will be used by Galaxy? We do it in run.sh but this is partly because we're running Galaxy under a non-login account, so there is no home directory.
Peter
Indeed, this workaround works! Thank you. I added these lines to the beginning of my run.sh: PATH="/opt/local/bin:/opt/local/sbin:$PATH" export $PATH Now, Galaxy can find Grinder, Velvet, etc.... Could Galaxy detect and use ~/.profile automatically if it exists? Alternatively, maybe there should be a place in the configuration file universe_wsgi.ini to specify which file to read environment variables from? Is it worth filing an enhancement request in the bug tracker? Again, thanks for the help. Florent