Is it possible to have plugins live somewhere that...
# nextflow-plugins
a
Is it possible to have plugins live somewhere that isn’t the home directory of the user running nextflow? We are running on an HPC that is quite locked down and if we have to pre-download plugins to each users’
$HOME/.nextflow
that could be quite onerous. We have a shared nextflow binary and I am wondering if it is possible to store plugins alongside that somehow?
👀 1
p
Can you use
NXF_HOME
?
But plugins are usually just a few thousand lines of code. Maximum a few kb in size I would have thought. Would that be so bad for people to download?
Ah, sorry - not the file size. The fact that you need to fetch in advance. Gotcha.
a
Yeah it’s mainly that anyone doing this would need to individually set up their copies. Ideally I would have a single location alongside our
nextflow
binary which would have a known set of plugins and we could keep a config that tracks which versions we currently have installed.
I’m not sure if setting
NXF_HOME
would have some consequences if different users were trying to run different versions of workflows (because we can access internal gitlab but not necessarily public github so not everything is needed locally)
m
I haven’t tested this, but I think you could have the plugins in a shared drive and provide a JSON to
NXF_PLUGINS_TEST_REPOSITORY
(read here) with the local paths for these plugins so that when Nextflow tries to install them, it’ll get them from your shared drive.
p
@Arthur if you fancy making a feature request issue about this on the Nextflow repo that'd be nice. It would be good to have an easier solution for this.
p
use
NXF_PLUGINS_DIR
env variable
gratitude thank you 1
p
Damn it, I knew that there was an env var like that! shakefist
I even searched the Nextflow docs for exactly that string 😅
Seems like it's documented in the nextflow repo under
plugins/README.md
but not in the main Nextflow docs.
Made an issue to look into consolidating these into the main docs..
✅ 2