diff --git a/runFaQCs/Dockerfile b/runFaQCs/Dockerfile index 5a65a30..06e3c5c 100644 --- a/runFaQCs/Dockerfile +++ b/runFaQCs/Dockerfile @@ -1,7 +1,7 @@ # syntax=docker/dockerfile:1 -FROM continuumio/miniconda3:23.5.2-0 +FROM continuumio/miniconda3:23.5.2-0 AS build -ENV container docker +ENV container=docker # dependencies for faqcs RUN apt-get update -y \ @@ -12,14 +12,28 @@ RUN apt-get update -y \ RUN conda config --add channels conda-forge \ && conda config --add channels bioconda +RUN conda init bash \ + && . ~/.bashrc \ + && conda create --name runFaQCs \ + && conda activate runFaQCs + # install faqcs -RUN conda install -c bioconda faqcs=2.10 +RUN conda install -n runFaQCs -c bioconda faqcs=2.10 +#RUN conda install -n runFaQCs -c conda-forge jellyfish +#RUN conda install -n runFaQCs -c conda-forge zlib +RUN conda install -c conda-forge conda-pack + +RUN conda-pack -n runFaQCs -o /tmp/env.tar && \ + mkdir /venv && cd /venv && tar xf /tmp/env.tar && \ + rm /tmp/env.tar -# add files -# ADD runQC_subroutines/* /opt/conda/bin/runQC_subroutines/ -ADD *.wdl /opt/conda/bin/ +RUN /venv/bin/conda-unpack -# ENV PATH="${PATH}:/opt/conda/bin/runQC_subroutines" +FROM debian:latest AS runtime -CMD ["/bin/bash"] +COPY --from=build /venv /venv +ENV PATH=/venv/bin:$PATH + +SHELL ["/bin/bash", "-c"] +CMD /bin/bash diff --git a/runFaQCs/nextflow.config b/runFaQCs/nextflow.config index 54200e2..203245b 100644 --- a/runFaQCs/nextflow.config +++ b/runFaQCs/nextflow.config @@ -1,5 +1,5 @@ -process.container = 'kaijli/runqc:1.0' -docker.enabled = true +process.container = 'apwat/run_faqcs:1.2' +singularity.enabled = true workflow.onComplete = { "rm -rf nf_assets".execute().text } diff --git a/runReadsToContig/Dockerfile b/runReadsToContig/Dockerfile index 24e2128..8ffea85 100644 --- a/runReadsToContig/Dockerfile +++ b/runReadsToContig/Dockerfile @@ -1,5 +1,5 @@ # syntax=docker/dockerfile:1 -FROM continuumio/miniconda3:23.5.2-0 +FROM continuumio/miniconda3:23.5.2-0 AS build ENV container=docker @@ -7,20 +7,40 @@ ENV container=docker RUN conda config --add channels conda-forge \ && conda config --add channels bioconda -# install dependencies -RUN conda install -c conda-forge r-base -RUN conda install -c conda-forge python=3.11 -RUN conda install -c bioconda perl-json -RUN conda install -c bioconda samclip=0.4.0 -RUN conda install -c bioconda bwa -RUN conda install -c bioconda bowtie2 -RUN conda install -c bioconda samtools=1.6 - -ADD bin/bam_to_fastq.pl /opt/conda/bin -ADD bin/contig_stats.pl /opt/conda/bin -ADD bin/ContigCoverageFold_plots_from_samPileup.pl /opt/conda/bin -ADD bin/fastq_utility.pm /opt/conda/bin -ADD bin/runReadsToContig.pl /opt/conda/bin -ADD bin/tab2Json_for_dataTable.pl /opt/conda/bin - -CMD ["/bin/bash"] \ No newline at end of file +RUN conda init bash \ + && . ~/.bashrc \ + && conda create --name readsToContig \ + && conda activate readsToContig + +RUN conda install -n readsToContig -c conda-forge r-base +RUN conda install -n readsToContig -c conda-forge python=3.11 +RUN conda install -n readsToContig -c bioconda perl-json +RUN conda install -n readsToContig -c bioconda samclip=0.4.0 +RUN conda install -n readsToContig -c bioconda bwa +RUN conda install -n readsToContig -c bioconda bowtie2 +RUN conda install -n readsToContig -c bioconda samtools=1.6 +RUN conda install -c conda-forge conda-pack + + +ADD bin/bam_to_fastq.pl /opt/conda/envs/readsToContig/bin +ADD bin/contig_stats.pl /opt/conda/envs/readsToContig/bin +ADD bin/ContigCoverageFold_plots_from_samPileup.pl /opt/conda/envs/readsToContig/bin +ADD bin/fastq_utility.pm /opt/conda/envs/readsToContig/bin +ADD bin/runReadsToContig.pl /opt/conda/envs/readsToContig/bin +ADD bin/tab2Json_for_dataTable.pl /opt/conda/envs/readsToContig/bin + +RUN conda-pack -n readsToContig -o /tmp/env.tar && \ + mkdir /venv && cd /venv && tar xf /tmp/env.tar && \ + rm /tmp/env.tar + +RUN /venv/bin/conda-unpack + +FROM debian:buster AS runtime +#RUN apk add --no-cache bash + +COPY --from=build /venv /venv +ENV PERL5LIB=/venv/lib/perl5/core_perl +ENV PATH=/venv/bin:$PATH + +SHELL ["/bin/bash", "-c"] +CMD /bin/bash \ No newline at end of file diff --git a/runReadsToContig/nextflow.config b/runReadsToContig/nextflow.config index b87796e..b4a673d 100644 --- a/runReadsToContig/nextflow.config +++ b/runReadsToContig/nextflow.config @@ -1,3 +1,6 @@ +process.container = 'apwat/run_r2c:1.3' +singularity.enabled=true + params { pairFile = "nf_assets/NO_FILE" unpairFile = "nf_assets/NO_FILE2" @@ -18,5 +21,3 @@ workflow.onComplete = { "rm -rf nf_assets".execute().text } -docker.enabled=true -process.container = 'apwat/run_r2c:1.1' \ No newline at end of file diff --git a/runReadsToContig/runReadsToContig.nf b/runReadsToContig/runReadsToContig.nf index eb1db53..9bb5504 100644 --- a/runReadsToContig/runReadsToContig.nf +++ b/runReadsToContig/runReadsToContig.nf @@ -1,6 +1,7 @@ #!/usr/bin/env nextflow process r2c { + debug true publishDir( path: "$params.outDir/AssemblyBasedAnalysis/readsMappingToContig", mode: 'copy' diff --git a/sra2fastq/nextflow.config b/sra2fastq/nextflow.config index 134a2fb..258a1d7 100644 --- a/sra2fastq/nextflow.config +++ b/sra2fastq/nextflow.config @@ -7,7 +7,7 @@ params { } process.container = 'kaijli/sra2fastq:1.6.3' -docker.enabled = true +singularity.enabled = true executor { submitRateLimit = '1/5sec' } \ No newline at end of file