title: How to create a docker image for shell scripts suite
body: <p>I want to create a docker image for <code>BBmap</code> suite which has a folder with multiple shell scripts (<code>${SHELLTOOLS}</code>). I have created a docker file below to create the docker image, but I also want to use helper script, <code>entrypoint.sh</code>. How do I make this docker file run with <code>entrypoint.sh</code>? Can someone please suggest me what I need to add/change to this docker file and <code>entrypoint.sh</code> so I can create a docker image and run it with the command below?</p>
  <p>My <code>Docker</code> file:</p>
  <pre><code>FROM openjdk:8-jre
  RUN    apt-get update \
      &amp;&amp; apt-get install -y \
          build-essential \
          openjdk-11-jre \
          wget \
      &amp;&amp; rm -rf /var/lib/apt/lists/*
  
  ENV BBMAP_VERSION 38.20
  ENV BBMAP_DIR /usr/local/bbmap
  
  WORKDIR /usr/local
  RUN set -eux; \
         wget -O bbmap.tar.gz https://sourceforge.net/projects/bbmap/files/BBMap_${BBMAP_VERSION}.tar.gz/download \
      &amp;&amp; tar -zxf bbmap.tar.gz \
      &amp;&amp; rm bbmap.tar.gz
  
  ENV PATH ${BBMAP_DIR}:${PATH}
  COPY ./entrypoint.sh /usr/local/bin/
  ## Add ENV for Shell scripts from BBMAP
  ENTRYPOINT [&quot;/usr/local/bin/entrypoint.sh&quot;]
  </code></pre>
  <p>My <code>entrypoint.sh</code>:</p>
  <pre><code>#!/bin/bash
  ${SHELLTOOL} -Xmx${MEM}g in=${sortedFQ} delimiter=${DELIM} prefixmode=f column=${COLNUM} out=${sampleFQ}%_#.fq
  </code></pre>
  <p>My command to run this on a LSF server:</p>
  <pre><code>export SHELLTOOL=&quot;/usr/local/bbmap/demuxbyname.sh&quot;; \
  export MEM=20; \
  export sortedFQ=&quot;/${PR}/${FULLSM}/paire_test_sorted.fastq&quot;; \
  export column=2; \
  export DELIM=&quot;:&quot;; \
  export COLNUM=2; \
  export sampleFQ=&quot;/${PR}/${FULLSM}/ADNI_1380&quot;
  bsub \
      -J &quot;${FULLSM}_bbduk_demulti&quot; \
      -o &quot;${BASE}/${FULLSM}_bbduk_demulti.%J&quot; \
      -n1 -W 1440 \
      -R &quot;rusage[mem=20192]&quot; \
      -q research-hpc \
      -a &quot;docker(username/bbmap:latest)&quot; \
  entrypoint.sh
  </code></pre>