Code Monkey home page Code Monkey logo

bowtie2-docker-singularity's Introduction

Docker Image CI

bowtie2-docker-singularity

Build Docker container for Bowtie 2 and (optionally) convert to Apptainer/Singularity.

Bowtie 2 is an ultrafast and memory-efficient tool for aligning sequencing reads to long reference sequences.
https://bowtie-bio.sourceforge.net/bowtie2/index.shtml

Requirements:

see https://bioconda.github.io/recipes/bowtie2/README.html
Install within image using micromamba
https://github.com/mamba-org/micromamba-docker

Build docker container:

1. For Bowtie 2 installation instructions:

https://bowtie-bio.sourceforge.net/bowtie2/manual.shtml#obtaining-bowtie-2

2. Build the Docker Image

To build image from the command line:

# Assumes current working directory is the top-level bowtie2-docker-singularity directory
docker build -t bowtie:2.5.1 . # tag should match software version

To test this tool from the command line:

docker run --rm -it bowtie:2.5.1 bowtie2 --help 

Optional: Conversion of Docker image to Singularity

3. Build a Docker image to run Singularity

(skip if this image is already on your system)
https://github.com/mattgalbraith/singularity-docker

4. Save Docker image as tar and convert to sif (using singularity run from Docker container)

docker images
docker save <Image_ID> -o bowtie2.5.1-docker.tar && gzip bowtie2.5.1-docker.tar # = IMAGE_ID of Bowtie2 image
docker run -v "$PWD":/data --rm -it singularity:1.1.5 bash -c "singularity build /data/bowtie2.5.1-docker.sif docker-archive:///data/bowtie2.5.1-docker.tar.gz"

NB: On Apple M1/M2 machines ensure Singularity image is built with x86_64 architecture or sif may get built with arm64

Next, transfer the bowtie2.5.1-docker.sif file to the system on which you want to run Bowtie 2 from the Singularity container

5. Test singularity container on (HPC) system with Singularity/Apptainer available

# set up path to the Singularity container
BOWTIE2_SIF=path/to/bowtie2.5.1-docker.sif

# Test that Bowtie 2 can run from Singularity container
singularity run $BOWTIE2_SIF bowtie2 --help # depending on system/version, singularity may be called apptainer

bowtie2-docker-singularity's People

Contributors

mattgalbraith avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.