Skip to content
This repository has been archived by the owner on Apr 11, 2023. It is now read-only.

Clusterflow doesn't work with Lmod modulefile system #124

Open
s-andrews opened this issue Jun 7, 2019 · 4 comments
Open

Clusterflow doesn't work with Lmod modulefile system #124

s-andrews opened this issue Jun 7, 2019 · 4 comments

Comments

@s-andrews
Copy link
Contributor

On our system we're using the newer Lmod environment module system rather than the original environment modules.

LMod is syntactically and API compatible with environment modules, but uses different back end commands. Because clusterflow doesn't call module but goes behind to call modulecmd then it fails with Lmod.

I'll attach a patch which will test for LMod and will support it if that's what people are running.

@s-andrews
Copy link
Contributor Author

s-andrews commented Jun 7, 2019

$ diff cf-orig cf
334,336c334,342
< if($CF_MODULES){
<       if (system('which modulecmd > /dev/null 2>&1')){
<               die( "ERROR - could not find modulecmd on the PATH. Aborting run.\n" .
---
>
> my $modulecmd = "modulecmd";
>
> if (exists $ENV{LMOD_CMD}) {
>               $modulecmd = $ENV{LMOD_CMD};
> }
>
> if($CF_MODULES){if (system("which $modulecmd > /dev/null 2>&1")){
>               die( "ERROR - could not find $modulecmd on the PATH. Aborting run.\n" .
1339c1345
<       my $mod_list = `modulecmd sh list 2>&1`;
---
>       my $mod_list = `$modulecmd sh list 2>&1`;

s-andrews added a commit to s-andrews/ClusterFlow that referenced this issue Jun 7, 2019
s-andrews added a commit to s-andrews/ClusterFlow that referenced this issue Jun 7, 2019
@ewels
Copy link
Owner

ewels commented Jun 7, 2019

Thanks! Can you just submit a PR instead of a diff?

@s-andrews
Copy link
Contributor Author

I already did :-)

@ewels
Copy link
Owner

ewels commented Jun 7, 2019

Ah you did already! x-ref #126

ewels added a commit that referenced this issue Jun 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants