aces / cbrain

CBRAIN is a flexible Ruby on Rails framework for accessing and processing of large data on high-performance computing infrastructures.
GNU General Public License v3.0
71 stars 42 forks source link

CbrainTask setup script to set HOME to the task's work directory #1250

Closed prioux closed 2 years ago

prioux commented 2 years ago

Some stupid programs try to create caches or config files in $HOME; when tasks are launched in containers that's not a problem because $HOME is set to the task's work directory. But for other tasks, we might as well do the same thing.

The setting should be done just before the actual scientific script is executed, so that HOME is still the normal home when the tool config prologues are executed (in case the admin uses $HOME during custom initialization commands).

prioux commented 2 years ago

Already got prototype code for that, it seems to work fine.

prioux commented 2 years ago

Implemented in https://github.com/aces/cbrain/commit/3ef9b7215873bc86a0dd46bf54a93d8ba9ba18a1