From cc8b8d32d772706071ce98bbe8bfbba81ae1ba3c Mon Sep 17 00:00:00 2001 From: whalleyt Date: Tue, 21 Nov 2023 18:11:54 +0000 Subject: [PATCH] permissions --- docker/Dockerfile.preprocessing-0.9.7r4 | 132 ++++++++++++++++++++++++ nextflow.config | 6 +- 2 files changed, 135 insertions(+), 3 deletions(-) create mode 100644 docker/Dockerfile.preprocessing-0.9.7r4 diff --git a/docker/Dockerfile.preprocessing-0.9.7r4 b/docker/Dockerfile.preprocessing-0.9.7r4 new file mode 100644 index 0000000..89267fc --- /dev/null +++ b/docker/Dockerfile.preprocessing-0.9.7r4 @@ -0,0 +1,132 @@ +FROM ubuntu:focal + +LABEL maintainer="pricea35@cardiff.ac.uk" \ +about.summary="container for the preprocessing workflow" + +ENV samtools_version=1.12 \ +bcftools_version=1.12 \ +htslib_version=1.12 \ +bedtools_version=2.29.2 \ +bowtie2_version=2.4.2 \ +fastp_version=0.20.1 \ +fastqc_version=0.11.9 \ +fqtools_version=2.3 \ +kraken2_version=2.1.1 \ +afanc_version=0.10.2 \ +mykrobe_version=0.12.1 \ +bwa_version=0.7.17 \ +mash_version=2.3 \ +fastani_version=1.33 + +ENV PACKAGES="procps curl git wget build-essential zlib1g-dev libncurses-dev libz-dev libbz2-dev liblzma-dev libcurl4-openssl-dev libgsl-dev rsync unzip ncbi-blast+ pigz jq libtbb-dev openjdk-11-jre-headless autoconf r-base-core locales locales-all" \ +PYTHON="python3 python3-pip python3-dev" \ +PYTHON_PACKAGES="biopython awscli boto3" + +ENV PATH=${PATH}:/usr/local/bin/mccortex/bin:/usr/local/bin/bwa-${bwa_version}:/opt/edirect \ +LD_LIBRARY_PATH=/usr/local/lib + +RUN export DEBIAN_FRONTEND="noninteractive" + +COPY bin/ /opt/bin/ +ENV PATH=/opt/bin:$PATH + + +RUN apt-get update \ +&& DEBIAN_FRONTEND="noninteractive" apt-get install -y $PACKAGES $PYTHON \ +&& pip3 install --upgrade pip \ +&& pip3 install $PYTHON_PACKAGES \ +&& ln -s /usr/bin/python3 /usr/bin/python + +RUN curl -fsSL https://github.com/samtools/samtools/archive/${samtools_version}.tar.gz | tar -xz \ +&& curl -fsSL https://github.com/samtools/htslib/releases/download/${htslib_version}/htslib-${htslib_version}.tar.bz2 | tar -xj \ +&& make -C samtools-${samtools_version} -j HTSDIR=../htslib-${htslib_version} \ +&& make -C samtools-${samtools_version} -j HTSDIR=../htslib-${htslib_version} prefix=/usr/local install \ +&& rm -r samtools-${samtools_version} \ +&& curl -fsSL https://github.com/samtools/bcftools/archive/refs/tags/${bcftools_version}.tar.gz | tar -xz \ +&& make -C bcftools-${bcftools_version} -j HTSDIR=../htslib-${htslib_version} \ +&& make -C bcftools-${bcftools_version} -j HTSDIR=../htslib-${htslib_version} prefix=/usr/local install \ +&& rm -r bcftools-${bcftools_version} + +RUN curl -fsSL https://github.com/alastair-droop/fqtools/archive/v${fqtools_version}.tar.gz | tar -xz \ +&& mv htslib-${htslib_version} fqtools-${fqtools_version} \ +&& cd fqtools-${fqtools_version} \ +&& mv htslib-${htslib_version} htslib \ +&& cd htslib \ +&& autoreconf -i \ +&& ./configure \ +&& make \ +&& make install \ +&& cd .. \ +&& make \ +&& mv bin/* /usr/local/bin \ +&& chmod +x /usr/local/bin/fqtools \ +&& cd .. \ +&& rm -r fqtools-${fqtools_version} + +RUN curl -fsSL https://github.com/arq5x/bedtools2/releases/download/v${bedtools_version}/bedtools-${bedtools_version}.tar.gz | tar -xz \ +&& make -C bedtools2 \ +&& mv bedtools2/bin/* /usr/local/bin \ +&& rm -r bedtools2 + +RUN curl -fsSL https://sourceforge.net/projects/bowtie-bio/files/bowtie2/${bowtie2_version}/bowtie2-${bowtie2_version}-source.zip -o bowtie2-${bowtie2_version}-source.zip \ +&& unzip bowtie2-${bowtie2_version}-source.zip \ +&& make -C bowtie2-${bowtie2_version} prefix=/usr/local install \ +&& rm -r bowtie2-${bowtie2_version} \ +&& rm bowtie2-${bowtie2_version}-source.zip + +RUN curl -fsSL https://github.com/OpenGene/fastp/archive/v${fastp_version}.tar.gz | tar -xz \ +&& cd fastp-${fastp_version} \ +&& make \ +&& make install \ +&& cd .. \ +&& rm -r fastp-${fastp_version} + +RUN wget https://www.bioinformatics.babraham.ac.uk/projects/fastqc/fastqc_v${fastqc_version}.zip \ +&& unzip fastqc_v${fastqc_version}.zip \ +&& chmod +x FastQC/fastqc \ +&& mv FastQC/* /usr/local/bin \ +&& rm fastqc_v${fastqc_version}.zip \ +&& rm -r FastQC + +RUN curl -fsSL https://github.com/DerrickWood/kraken2/archive/v${kraken2_version}.tar.gz | tar -xz \ +&& cd kraken2-${kraken2_version} \ +&& ./install_kraken2.sh /usr/local/bin \ +&& cd .. + +RUN curl -fsSL https://github.com/ArthurVM/Afanc/archive/refs/tags/v${afanc_version}-alpha.tar.gz | tar -xz \ +&& cd Afanc-${afanc_version}-alpha \ +&& pip3 install ./ \ +&& cd .. \ +&& curl -fsSL "https://github.com/marbl/Mash/releases/download/v${mash_version}/mash-Linux64-v${mash_version}.tar" | tar -x \ +&& mv mash-Linux64-v${mash_version}/mash /usr/local/bin \ +&& rm -r mash-Linux* \ +&& wget https://github.com/ParBLiSS/FastANI/releases/download/v${fastani_version}/fastANI-Linux64-v${fastani_version}.zip \ +&& unzip fastANI-Linux64-v${fastani_version}.zip \ +&& mv fastANI /usr/local/bin + +RUN sh -c "$(curl -fsSL ftp://ftp.ncbi.nlm.nih.gov/entrez/entrezdirect/install-edirect.sh)" \ +&& mkdir -p /opt/edirect \ +&& mv /root/edirect/* /opt/edirect + +RUN git clone --recursive -b geno_kmer_count https://github.com/phelimb/mccortex \ +&& make -C mccortex \ +&& mv mccortex /usr/local/bin \ +&& curl -fsSL mykrobe-${mykrobe_version}.tar.gz https://github.com/Mykrobe-tools/mykrobe/archive/v${mykrobe_version}.tar.gz | tar -xz \ +&& cd mykrobe-${mykrobe_version} \ +&& pip3 install requests \ +&& pip3 install . \ +&& ln -s /usr/local/bin/mccortex/bin/mccortex31 /usr/local/lib/python3.8/dist-packages/mykrobe/cortex/mccortex31 \ +&& mykrobe panels update_metadata \ +&& mykrobe panels update_species all \ +&& cd .. + +RUN curl -fsSL https://github.com/lh3/bwa/archive/v${bwa_version}.tar.gz | tar -C /usr/local/bin -xz \ +&& make -C /usr/local/bin/bwa-${bwa_version} \ +&& chmod +x /usr/local/bin/bwa-${bwa_version}/bwa + +RUN unset DEBIAN_FRONTEND + +ENV LC_ALL en_US.UTF-8 \ +LANG en_US.UTF-8 \ +LANGUAGE en_US.UTF-8 + diff --git a/nextflow.config b/nextflow.config index 9744744..ef42345 100644 --- a/nextflow.config +++ b/nextflow.config @@ -90,7 +90,7 @@ profiles { withLabel:high_memory { memory = '18GB' } withLabel:preprocessing { - container = "quay.io/pathogen-genomics-cymru/preprocessing:0.9.7r2" + container = "quay.io/pathogen-genomics-cymru/preprocessing:0.9.7r4" } withLabel:getversion{ @@ -111,11 +111,11 @@ profiles { } withLabel:clockwork { - container = "quay.io/pathogen-genomics-cymru/clockwork:0.9.7r2" + container = "quay.io/pathogen-genomics-cymru/clockwork:0.9.7r3" } withLabel:vcfpredict { - container = "quay.io/pathogen-genomics-cymru/vcfpredict:0.9.7r2" + container = "quay.io/pathogen-genomics-cymru/vcfpredict:0.9.7r3" } } params{