Skip to content

Running on Linux

Chris Jackson edited this page Jun 30, 2023 · 21 revisions

NOTE: the following was tested with:

  • Nextflow version 21.04.1 build 5556
  • Java version openjdk 11.0.8-internal 2020-07-14

To run the hybpiper.nf pipeline on a Linux system, all you need to install is Nextflow version 21.04.1 or later (requires Java version 8 or later) and Singularity version 3.2 or later (it might work with earlier versions on Singularity, but I haven’t tested it).

  1. I recommend installing Singularity by compiling it from source code and installing as root. For instructions on how to do this, see here. Although you can install Singularity via the package manager conda, the conda version has some restrictions that can cause problems on some Linux distributions (for further reading, see here and here).

  2. Once Singularity is installed, you can download the hybpiper-paragone Singularity container (file size 2.4 GB) using the command:

    singularity pull library://chrisjackson-pellicle/collection/hybpiper-paragone:latest

    NOTE that the snippet :latest in the download command refers to the tag of the most up-to-date version of this container. When downloaded in this way, Singularity will automatically change the name of the container to hybpiper-paragone_latest.sif.

  3. Download the HybPiper Nextflow pipeline and its associated config file by cloning this gitgub repo using the command:

    git clone https://github.com/chrisjackson-pellicle/hybpiper-nf.git

  4. Open the Nextflow config file hybpiper.config and change the lines:

    container = 'library://chrisjackson-pellicle/collection/hybpiper-paragone:latest'

    ...to point towards the full path of the hybpiper-paragone_latest.sif container file you’ve just downloaded to your system e.g.

    container = 'file:///home/cjackson/hybpiper-paragone_latest.sif'

    NOTE the prefix file:// before the full path name.

    ALTERNATIVELY:

    Just run the Nextflow pipeline with the config file as provided i.e. with the line

    container = 'library://chrisjackson-pellicle/collection/hybpiper-paragone:latest'

NOTE: The first time the pipeline is run it will download the Singularity image to a folder in your current working directory called singularity-images. The downside of this approach is that if you run the script in another directory (e.g. on a different dataset), you’ll need to download the Singularity image again. So, you’re probably better off manually downloading it, and changing the config file to point towards the full path.

You can now use the following command to view the help text for the hybpiper.nf pipeline:

nextflow run hybpiper.nf -c hybpiper.config

See full options here.

You could then run the pipeline using the command e.g.:

nextflow run hybpiper.nf -c hybpiper.config -entry assemble -profile standard_singularity --illumina_reads_directory reads_for_hybpiper --targetfile_dna Angiosperms353_targetSequences.fasta