Closed YichaoOU closed 1 year ago
Yes. This is quite easily done. If you run on premise with an executor such as Slurm -- you can see how to do something by using the explanations on the Jackson Laboratory Alternative Splicing Pipeline workflow here. Using the config file for running on sumner (the name of the on premise HPC) https://github.com/TheJacksonLaboratory/splicing-pipelines-nf/blob/master/conf/executors/sumner.config and how to use singulatory -- assumed by sumner https://github.com/TheJacksonLaboratory/splicing-pipelines-nf/blob/master/conf/executors/singularity.config
Thanks!
Usually in nf-core, you can directly add -profile singularity
, but it seems this can not be used here? because I got this error:
nextflow run main.nf --config conf/test_with_sqanti.config -profile singularity
Unknown configuration profile: 'singularity'
Thanks, Yichao
Hi @YichaoOU ,
I always like to remind people that there is no magic in programming. The nf-core community has a defined profile for the option in a workflow that allows you to specify -profile singularity. If you look here at the sarek
workflow https://github.com/nf-core/sarek/blob/master/nextflow.config you will see that there is a profile called singularity
. We can add this as a feature request or you can modify your own nextflow.config file to have the same.
Code snippet here:
profiles {
debug { process.beforeScript = 'echo $HOSTNAME' }
conda {
params.enable_conda = true
charliecloud.enabled = false
docker.enabled = false
podman.enabled = false
shifter.enabled = false
singularity.enabled = false
}
mamba {
conda.useMamba = true
params.enable_conda = true
charliecloud.enabled = false
docker.enabled = false
podman.enabled = false
shifter.enabled = false
singularity.enabled = false
}
docker {
docker.enabled = true
docker.userEmulation = { params.use_gatk_spark ? false : true }.call()
charliecloud.enabled = false
podman.enabled = false
shifter.enabled = false
singularity.enabled = false
}
singularity {
singularity.autoMounts = true
singularity.enabled = true
charliecloud.enabled = false
docker.enabled = false
podman.enabled = false
shifter.enabled = false
}
podman {
podman.enabled = true
charliecloud.enabled = false
docker.enabled = false
shifter.enabled = false
singularity.enabled = false
}
shifter {
shifter.enabled = true
charliecloud.enabled = false
docker.enabled = false
podman.enabled = false
singularity.enabled = false
}
charliecloud {
charliecloud.enabled = true
docker.enabled = false
podman.enabled = false
shifter.enabled = false
singularity.enabled = false
}
gitpod {
executor.cpus = 16
executor.memory = 60.GB
executor.name = 'local'
}
If you would like, you can create an issue as a code improvement and we will add it as we can. It isn't a bad suggestion - but shouldn't hold you up as you can adjust yours to do the same. If you make a pull request with the change we can merge it after testing. Cheers!
Hello,
Our HPC can't run docker applications.
Is this possible that you can make a singularity container?
Thank you! Yichao