Skip to content

Commit

Permalink
Merge pull request #19 from sanger-tol/longranger_lsf
Browse files Browse the repository at this point in the history
Updated config for running longranger with and without LSF
  • Loading branch information
ksenia-krasheninnikova authored Sep 11, 2023
2 parents 3768dec + dfafb26 commit c6ce6fb
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 8 deletions.
17 changes: 17 additions & 0 deletions conf/longranger_lsf_sanger.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
/*
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Nextflow config file for running longranger on LSF at the Sanger
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*/

process {
withName: LONGRANGER_ALIGN {
// Same arguments as in conf/modules.config but with the LSF job mode
ext.args = "--disable-ui --nopreflight --jobmode=lsf"
}
}

// Make the LSF configuration available to the container / longranger
singularity.envWhitelist = "LSF_BINDIR,LSF_SERVERDIR,LSF_LIBDIR,LSF_ENVDIR"
singularity.runOptions = "-B ${projectDir}/assets/martian.lsf.template:/opt/longranger-2.2.2/martian-cs/2.3.2/jobmanagers/lsf.template -B /software -B /etc/lsf.conf --env APPEND_PATH=$LSF_BINDIR:$LSF_SERVERDIR:/software/singularity-v3.9.0/bin"

23 changes: 17 additions & 6 deletions conf/modules.config
Original file line number Diff line number Diff line change
Expand Up @@ -367,8 +367,9 @@ process {
// Set up of the polishing pipeline

withName: LONGRANGER_MKREF {
envWhitelist = "LSF_BINDIR,LSF_SERVERDIR,LSF_LIBDIR,LSF_ENVDIR"
runOptions = "-B ${projectDir}/martian.lsf.template:/opt/longranger-2.2.2/martian-cs/2.3.2/jobmanagers/lsf.template -B /software -B /etc/lsf.conf --env APPEND_PATH=$LSF_BINDIR:$LSF_SERVERDIR:/software/singularity-v3.9.0/bin"
if(System.getenv('GITHUB_ACTION') != null ) {
container = "ghcr.io/sanger-tol/longranger:2.2.2-c3"
}
publishDir = [
path: { "${params.outdir}/${meta.id}.${params.hifiasm}/polishing" },
mode: params.publish_dir_mode,
Expand All @@ -377,14 +378,11 @@ process {
}

withName: LONGRANGER_ALIGN {
// Keep in sync with `longranger_lsf_sanger.config`
ext.args = "--disable-ui --nopreflight"
if(System.getenv('GITHUB_ACTION') != null ) {
container = "ghcr.io/sanger-tol/longranger:2.2.2-c3"
}
else {
envWhitelist = "LSF_BINDIR,LSF_SERVERDIR,LSF_LIBDIR,LSF_ENVDIR"
runOptions = "-B ${projectDir}/martian.lsf.template:/opt/longranger-2.2.2/martian-cs/2.3.2/jobmanagers/lsf.template -B /software -B /etc/lsf.conf --env APPEND_PATH=$LSF_BINDIR:$LSF_SERVERDIR:/software/singularity-v3.9.0/bin"
}
publishDir = [
path: { "${params.outdir}/${meta.id}.${params.hifiasm}/polishing" },
mode: params.publish_dir_mode,
Expand Down Expand Up @@ -677,3 +675,16 @@ process {
//End of Set up of assmebly stats subworkflow

}


/*
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Extra profiles defined to override some of the above parameters
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Importantly, these profiles *cannot* be defined in the main `nextflow.config`,
otherwise they would be loaded _before_ this `conf/modules.config`.
----------------------------------------------------------------------------------------
*/
profiles {
longranger_lsf_sanger { includeConfig 'longranger_lsf_sanger.config' }
}
2 changes: 0 additions & 2 deletions nextflow.config
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,6 @@ profiles {
shifter.enabled = false
apptainer.enabled = false
charliecloud.enabled = false
singularity.envWhitelist = "LSF_BINDIR,LSF_SERVERDIR,LSF_LIBDIR,LSF_ENVDIR"
singularity.runOptions = "-B ${projectDir}/assets/martian.lsf.template:/opt/longranger-2.2.2/martian-cs/2.3.2/jobmanagers/lsf.template -B /software -B /etc/lsf.conf --env APPEND_PATH=$LSF_BINDIR:$LSF_SERVERDIR:/software/singularity-v3.9.0/bin"
}
podman {
podman.enabled = true
Expand Down

0 comments on commit c6ce6fb

Please sign in to comment.