From bcec2fb14f97a7f06755dbddbd904e6f930b71cb Mon Sep 17 00:00:00 2001
From: Cedric Cabau <cedric.cabau@inra.fr>
Date: Fri, 24 May 2019 14:01:23 +0200
Subject: [PATCH] Update doc after the substitution of the embedded transrate
 by a patch

---
 doc/index.html         |  4 +--
 doc/install.html       | 81 ++++++++++++++++++++++++++----------------
 doc/lib/src/Dockerfile | 20 +++++++----
 3 files changed, 66 insertions(+), 39 deletions(-)

diff --git a/doc/index.html b/doc/index.html
index f41b5db..cf05c01 100644
--- a/doc/index.html
+++ b/doc/index.html
@@ -116,9 +116,9 @@
 							<b>Version 1.92</b> (2019-05)
 								<ul>
 									<li>External tools compatibility: TransDecoder-v5.0, Trinity-v2.8.4.</li>
-									<li>Add option --assemblies to runMeta to perform meta-assembly directly from fasta files.</li>
+									<li>Add option <kbd>--assemblies</kbd> to runMeta to perform meta-assembly directly from fasta files.</li>
 									<li>Add SLURM scheduler compatibility.</li>
-									<li>Add TransRate custom version to reduce snap aligner crashes.</li>
+									<li>Provide a patch to reduce TransRate memory requirement.</li>
 									<li>Fix various bugs.</li>
 									<li>Update Docker image.</li>
 								</ul>
diff --git a/doc/install.html b/doc/install.html
index 74987f9..5e4784a 100644
--- a/doc/install.html
+++ b/doc/install.html
@@ -67,11 +67,11 @@
 			<p>Pull the Docker image.</p>
 			<pre class="prettyprint">docker pull sigenae/drap</pre>
 			<p>Create the Docker container.</p>
-			<pre class="prettyprint">docker create --name drap --privileged -v /mnt/scratch:/docker/scratch -i -t docker.io/sigenae/drap /bin/bash</pre>
+			<pre class="prettyprint">docker create --name drap --privileged -v /mnt/scratch:/docker/scratch -i -t sigenae/drap:latest /bin/bash</pre>
 			<p>Start the Docker container and get bash into the running container.</p>
 			<pre class="prettyprint">docker start drap<br>docker exec -i -t drap /bin/bash</pre>
 			<p>The Docker container is configured to run with 120G of RAM and 6 CPU's.</p>
-			<p>DRAP is installed in the Docker container at '/usr/local/src/drap-v1.91'. Use that path as the INSTALL_FOLDER in the DRAP documentation.</p>
+			<p>DRAP install directory in the Docker container is <kbd>/usr/local/src/drap</kbd>. Use that path as the INSTALL_FOLDER in the DRAP documentation.</p>
 			<div class="page-header">
 				<h1>Local install</h1>
 			</div>
@@ -115,63 +115,63 @@
 				<li>
 					bedtools
 					<ul>
-						<li>Version = <span class="badge">2.22.1</span></li>
+						<li>Version = <span class="badge">2.26</span></li>
 						<li><a href="http://bedtools.readthedocs.org/en/latest/content/installation.html">Download</a></li>
 					</ul>	
 				</li>
 				<li>
 					blat
 					<ul>
-						<li>Version = <span class="badge">35</span></li>
+						<li>Version = <span class="badge">36</span></li>
 						<li><a href="https://genome.ucsc.edu/FAQ/FAQblat.html#blat3">Download</a></li>
 					</ul>	
 				</li>
 				<li>
 					bowtie
 					<ul>
-						<li>Version = <span class="badge">2.2.9</span></li>
-						<li><a href="https://sourceforge.net/projects/bowtie-bio/files/bowtie2/2.2.9/">Download</a></li>
+						<li>Version = <span class="badge">2.3</span></li>
+						<li><a href="https://sourceforge.net/projects/bowtie-bio/files/bowtie2/2.3.4.1/">Download</a></li>
 					</ul>	
 				</li>
 				<li>
 					busco
 					<ul>
-						<li>Version = <span class="badge">3.0</span></li>
+						<li>Version = <span class="badge">3.1</span></li>
 						<li><a href="http://busco.ezlab.org/">Download</a></li>
 					</ul>	
 				</li>
 				<li>
 					bwa
 					<ul>
-						<li>Version = <span class="badge">0.7.15</span></li>
+						<li>Version = <span class="badge">0.7.17</span></li>
 						<li><a href="http://sourceforge.net/projects/bio-bwa/files/">Download</a></li>
 					</ul>	
 				</li>
 				<li>
 					cd-hit
 					<ul>
-						<li>Version = <span class="badge">4.6</span></li>
+						<li>Version = <span class="badge">4.7</span></li>
 						<li><a href="https://github.com/weizhongli/cdhit">Download</a></li>
 					</ul>
 				</li>
 				<li>
 					cutadapt
 					<ul>
-						<li>Version = <span class="badge">1.8.3</span></li>
+						<li>Version = <span class="badge">1.15</span></li>
 						<li><a href="https://github.com/marcelm/cutadapt">Download</a></li>
 					</ul>
 				</li>
 				<li>
 					dc
 					<ul>
-						<li>Version = <span class="badge">1.3.95</span></li>
+						<li>Version = <span class="badge">1.4</span></li>
 						<li><a href="https://www.gnu.org/software/bc/">Download</a></li>
 					</ul>
 				</li>
 				<li>
 					exonerate
 					<ul>
-						<li>Version = <span class="badge"> 2.2.0</span></li>
+						<li>Version = <span class="badge"> 2.4</span></li>
 						<li><a href="http://www.ebi.ac.uk/about/vertebrate-genomics/software/exonerate">Download</a></li>
 					</ul>	
 				</li>
@@ -182,7 +182,7 @@
 				<li>
 					express
 					<ul>
-						<li>Version = <span class="badge">1.5.1</span></li>
+						<li>Version = <span class="badge">1.5</span></li>
 						<li><a href="https://github.com/adarob/eXpress">Download</a></li>
 					</ul>	
 				</li>
@@ -196,14 +196,14 @@
 				<li>
 					getorf
 					<ul>
-						<li>Version = <span class="badge">EMBOSS: 6.4.0.0</span></li>
+						<li>Version = <span class="badge">EMBOSS: 6.6.0.0</span></li>
 						<li><a href="http://emboss.sourceforge.net/download">Download</a></li>
 					</ul>	
 				</li>
 				<li>
 					khmer
 					<ul>
-						<li>Version = <span class="badge">2.0</span></li>
+						<li>Version = <span class="badge">2.1</span></li>
 						<li><a href="https://github.com/dib-lab/khmer">Download</a></li>
 					</ul>
 				</li>
@@ -217,8 +217,8 @@
 				<li>
 					NCBI Blast+
 					<ul>
-						<li>Version = <span class="badge">2.2.29</span></li>
-						<li><a href="ftp://ftp.ncbi.nih.gov/blast/executables/blast+/2.2.29/">Download</a></li>
+						<li>Version = <span class="badge">2.6</span></li>
+						<li><a href="ftp://ftp.ncbi.nih.gov/blast/executables/blast+/2.6.0/">Download</a></li>
 					</ul>	
 				</li>
 				<li>
@@ -231,14 +231,14 @@
 				<li>
 					oases
 					<ul>
-						<li>Version = <span class="badge">0.2.06</span></li>
+						<li>Version = <span class="badge">0.2.09</span></li>
 						<li><a href="https://github.com/dzerbino/oases/tree/master">Download</a></li>
 					</ul>
 				</li>
 				<li>
 					parallel
 					<ul>
-						<li>Version = <span class="badge">parallel-20141022</span></li>
+						<li>Version = <span class="badge">parallel-20161222</span></li>
 						<li><a href="http://ftp.gnu.org/gnu/parallel/">Download</a></li>
 					</ul>	
 				</li>
@@ -249,13 +249,20 @@
 				<li>
 					rsync
 					<ul>
-						<li>Version = <span class="badge">3.0.6</span></li>
+						<li>Version = <span class="badge">3.1.2</span></li>
+					</ul>	
+				</li>
+				<li>
+					salmon
+					<ul>
+						<li>Version = <span class="badge">0.13</span></li>
+						<li><a href="https://combine-lab.github.io/salmon/getting_started/">Download</a></li>
 					</ul>	
 				</li>
 				<li>
 					samtools
 					<ul>
-						<li>Version = <span class="badge">1.3</span></li>
+						<li>Version = <span class="badge">1.7</span></li>
 						<li><a href="http://www.htslib.org/download/">Download</a></li>
 					</ul>	
 				</li>
@@ -268,7 +275,7 @@
 				<li>
 					STAR
 					<ul>
-						<li>Version = <span class="badge">2.4.0i</span></li>
+						<li>Version = <span class="badge">2.5</span></li>
 						<li><a href="https://github.com/alexdobin/STAR/releases">Download</a></li>
 					</ul>	
 				</li>
@@ -282,28 +289,28 @@
 				<li>
 					TransDecoder
 					<ul>
-						<li>Version = <span class="badge">2.0.1</span></li>
+						<li>Version = <span class="badge">5.0</span></li>
 						<li><a href="http://transdecoder.github.io/">Download</a></li>
 					</ul>
 				</li>
 				<li>
 					TransRate
 					<ul>
-						<li>Version = <span class="badge">1.0.1</span></li>
+						<li>Version = <span class="badge">1.0.3</span></li>
 						<li><a href="http://hibberdlab.com/transrate/installation.html">Download</a></li>
 					</ul>
 				</li>
 				<li>
 					trim_galore
 					<ul>
-						<li>Version = <span class="badge">0.4.0</span></li>
+						<li>Version = <span class="badge">0.4.2</span></li>
 						<li><a href="http://www.bioinformatics.babraham.ac.uk/projects/trim_galore/">Download</a></li>
 					</ul>
 				</li>
 				<li>
 					Trinity
 					<ul>
-						<li>Version = <span class="badge">2.4.0</span></li>
+						<li>Version = <span class="badge">2.8.4</span></li>
 						<li><a href="https://github.com/trinityrnaseq/trinityrnaseq/releases">Download</a></li>
 					</ul>
 				</li>
@@ -324,7 +331,7 @@
 			</div>
 			<div>
 				<h2 id="configuration_file">drap.cfg</h2>
-				<p>This configuration file, common to all modules, is divided into several sections:
+				<p>This configuration file, common to all modules, is divided into several sections:</p>
 <pre>
 [SCHEDULER]
 type = local  # This value can be 'local', 'sge' or 'slurm'
@@ -342,10 +349,16 @@ type = local  # This value can be 'local', 'sge' or 'slurm'
 				<p>If one of the software listed in the section SOFTWARES is not directly accessible, add the bin folder of this software in the section PATH (see '<a href="#check_dependencies">Check dependencies installation</a>').</p>
 <pre>
 [ENV] # Commands to execute to set the environnement (i.e. module load)
-preprocess_env = module load compiler/gcc-4.9.1; ... # for Khmer package
+# Stages are:
+# runDrap       [preprocess oases trinity merge clustering asm post_asm rmbt_editing rmbt_filtering postprocess reference]
+# runMeta       [meta_merge meta_longest_orf meta_cluster_orf meta_longest_contig meta_cluster_contig meta_index meta_rmbt meta_filter meta_postprocess meta_reference]
+# runAssessment [assemblyMetrics inclusion chimera orf mapping scoring prot busco]
+# Syntax is &lt;stageName&gt;_env = command_1; [ command_2; ...]
+preprocess_env = module load compiler/gcc-4.9.1 # for Khmer package
+busco_env      = module load system/Python-3.6.3 bioinfo/augustus-3.3 system/R-3.4.3 bioinfo/busco-3.0.2
 ...
 </pre>
-				<p>If one of the software listed in the section SOFTWARES need a specific environment, add the commands to execute to complete the step using this specific tool in this section. The example above shows how to load a module named compiler/gcc-4.9.1 needed to run scripts from the Khmer package. Scripts from this package are used to complete the preprocess step (see the <a href="third_party_tools.html">DRAP 3rd Party Tools</a> table), so you should give the step name followed by _env and the command to execute at the step start.
+				<p>If one of the software listed in the section SOFTWARES need a specific environment, add the commands required to set this environment in this section. The example above shows how to load a module named compiler/gcc-4.9.1 needed to run scripts from the Khmer package. Scripts from this package are used to complete the preprocess step (see the <a href="third_party_tools.html">DRAP 3rd Party Tools</a> table), so you should give the step name followed by _env and the command to execute at the step start.
 <pre>
 [DATABASE] # External data sources
 ...
@@ -363,7 +376,15 @@ preprocess_env = module load compiler/gcc-4.9.1; ... # for Khmer package
 </pre>
 				<p>Depending on the resources available on your computing infrastructure, adjust the resources requested for some workflow specific task or step.</p>
 			</div>
-			
+			<div class="page-header">
+				<h1>Patching TransRate</h1>
+			</div>
+			<div>
+				<p>From a list of fastq (or pair of fastq) files as input, TransRate and snap-aligner try to produce a single output file in bam format. With a lot of reads, snap-aligner is not able to sort the bam file without a very large amount of memory. To reduce the required memory, this patch will run snap-aligner with each fastq or pair of fastq from the list and delegate merging and sorting to samtools. Please be sure to have the samtools command in your PATH because the availability of this new dependency is not checked by the TransRate patched version.</p>
+<pre>cd <b>TRANSRATE_INSTALL_DIR</b>/lib/app/lib/transrate
+patch -b < <b>INSTALL_DIR</b>/plugins/drap-transrate/transrate.patch
+</pre>
+			</div>
 			<div class="page-header">
 				<h1>Test install</h1>
 			</div>
diff --git a/doc/lib/src/Dockerfile b/doc/lib/src/Dockerfile
index 3aaebbd..2158b78 100644
--- a/doc/lib/src/Dockerfile
+++ b/doc/lib/src/Dockerfile
@@ -1,4 +1,4 @@
-FROM ubuntu
+FROM ubuntu:18.04
 MAINTAINER sigenae "sigenae-support@listes.inra.fr"
 ENV REFRESHED_AT 2019-05-20
 
@@ -42,6 +42,7 @@ RUN apt-get update && apt-get install -y --no-install-recommends apt-utils\
 	ncbi-blast+ \
 	ncbi-tools-bin \
 	parallel \
+	patch \
 	python3-setuptools \
 	python \
 	python-biopython \
@@ -51,7 +52,6 @@ RUN apt-get update && apt-get install -y --no-install-recommends apt-utils\
 	rna-star \
 	rsync \
 	ruby-dev \
-	salmon \
 	samtools \
 	transdecoder \
 	wget \
@@ -99,7 +99,7 @@ RUN cd /usr/local/bin \
 ## -- install fastq_illumina_filter -- ##
 RUN cd /usr/local/bin \
 	&& wget http://cancan.cshl.edu/labmembers/gordon/fastq_illumina_filter/release/0.1/fastq_illumina_filter-Linux-x86_64 \
-	&& chmod +x fastq_illumitrinityrnaseq-Trinity-v2.8.4/na_filter-Linux-x86_64 \
+	&& chmod +x fastq_illumina_filter-Linux-x86_64 \
 	&& ln -s fastq_illumina_filter-Linux-x86_64 fastq_illumina_filter
 
 ## -- install seqclean -- ##
@@ -127,6 +127,13 @@ RUN cd /usr/local/src \
 ENV PATH /usr/local/src/tgicl_linux/bin:$PATH
 ENV PERL5LIB /usr/local/src/tgicl_linux:$PERL5LIB
 
+## -- install salmon -- ##
+RUN cd /usr/local/src \
+	&& mkdir salmon-0.13.1_linux_x86_64 \
+	&& curl -SL https://github.com/COMBINE-lab/salmon/releases/download/v0.13.1/salmon-0.13.1_linux_x86_64.tar.gz | tar -xz -C salmon-0.13.1_linux_x86_64 --strip-components 1 \
+	&& cd salmon-0.13.1_linux_x86_64 \
+	&& ln -s $PWD/bin/salmon /usr/local/bin/salmon 
+
 ## -- install trinity -- ##
 RUN cd /usr/local/src \
 	&& curl -SL https://github.com/trinityrnaseq/trinityrnaseq/archive/Trinity-v2.8.4.tar.gz | tar -xz \
@@ -137,14 +144,13 @@ RUN cd /usr/local/src \
 	&& rm -rf $PWD/sample_data
 ENV PATH /usr/local/src/trinityrnaseq-Trinity-v2.8.4/trinity-plugins/BIN:$PATH
 
-## -- install transRate -- ##
+## -- install transrate -- ##
 RUN cd /usr/local/src \
         && curl -SL https://bintray.com/artifact/download/blahah/generic/transrate-1.0.3-linux-x86_64.tar.gz | tar -xz \
         && cd transrate-1.0.3-linux-x86_64 \
         && ./transrate --install-deps ref \
-	&& ln -s $PWD/transrate /usr/local/bin/transrate
+	&& ln -s $PWD/transrate /usr/local/bin/transrate \
 	&& rm -f bin/librt.so.1
-ENV PATH /usr/local/src/transrate-1.0.3-linux-x86_64:/usr/local/src/transrate-1.0.3-linux-x86_64/bin:/usr/local/src/transrate-1.0.3-linux-x86_64/lib/app/ruby/2.2.0/bin:$PATH
 
 ## -- install busco -- ##
 RUN cd /usr/local/src \
@@ -197,7 +203,7 @@ RUN cd /usr/local/src/drap \
 	&& sed -i -e 's|/path/to/busco_directory|/usr/local/src/busco/datasets|' cfg/drap.cfg \
 	&& sed -i -e 's|type = .*|type = local|' cfg/drap.cfg \
 	# correcting tgicl conflict version
-	&& sed -i -e 's/tgicl -F/tgicl/' bin/runAssembly.sh
+	&& sed -i -e 's/tgicl -F/tgicl/' bin/runAssembly.sh \
 	# patching transrate
 	&& cd /usr/local/src/transrate-1.0.3-linux-x86_64/lib/app/lib/transrate \
 	&& patch -b < /usr/local/src/drap/plugins/drap-transrate/transrate.patch
-- 
GitLab