Skip to content

Commit

Permalink
Update ShapeIt4 from version 4.1.3 to version 4.2.1 (#92)
Browse files Browse the repository at this point in the history
* Update ShapeIt4 from version 4.1.3 to version 4.2.1
  • Loading branch information
jessicaway authored Jul 1, 2021
1 parent e989be9 commit f846808
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 20 deletions.
2 changes: 1 addition & 1 deletion dockerfiles/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ A farm5-specific docker image, providing dependencies for the iRODS import and b
- samplevcftozarr - `docker build . --tag=samplevcftozarr:1.0`
- sampleselectvariants - `docker build . --tag=sampleselectvarians:1.0`
- whatshap - `docker build . --tag=whatshap:1.0`
- shapeit4 - `docker build . --tag=shapeit4:4.1.3`
- shapeit4 - `docker build . --tag=shapeit4:4.2.1`
- bcftools - `docker build . --tag=bcftools:1.11`
- import - `docker build . --tag=sangerpathogens/irods:4.1.12`

41 changes: 25 additions & 16 deletions dockerfiles/Shapeit4/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,22 +1,31 @@
FROM bashell/alpine-bash@sha256:965a718a07c700a5204c77e391961edee37477634ce2f9cf652a8e4c2db858ff
FROM ubuntu:20.04
# Suppress interactive output from installs

ARG shapeit4_version=4.1.3
ENV DEBIAN_FRONTEND=noninteractive
ARG shapeit4_version=4.2.1
ARG htslib_version=1.11
ARG boost_version_with_dots=1.74.0
ARG boost_version=1_74_0

RUN apk update \
&& apk add --no-cache \
build-base \
zlib-dev \
bzip2-dev \
xz-dev \
ncurses-dev \
ca-certificates \
wget
RUN apt-get update && \
apt-get -y --no-install-recommends install \
ca-certificates \
libbz2-dev \
libcurl4-openssl-dev \
liblzma-dev \
libssl-dev \
libncurses5-dev \
autoconf \
automake \
bzip2 \
gcc \
g++ \
make \
wget \
zlib1g-dev \
libboost-all-dev

WORKDIR /tmp

# Install htslib to get bgzip and tabix
RUN wget -q https://github.com/samtools/htslib/releases/download/${htslib_version}/htslib-${htslib_version}.tar.bz2 && \
tar xf htslib-${htslib_version}.tar.bz2 && \
Expand All @@ -25,7 +34,7 @@ RUN wget -q https://github.com/samtools/htslib/releases/download/${htslib_versio
./configure && \
make install

RUN wget -q https://dl.bintray.com/boostorg/release/${boost_version_with_dots}/source/boost_${boost_version}.tar.gz && \
RUN wget -q https://boostorg.jfrog.io/artifactory/main/release/${boost_version_with_dots}/source/boost_${boost_version}.tar.gz && \
tar xf boost_${boost_version}.tar.gz && \
rm boost_${boost_version}.tar.gz && \
cd boost_${boost_version} && \
Expand All @@ -36,14 +45,14 @@ RUN wget -q https://github.com/odelaneau/shapeit4/archive/v${shapeit4_version}.t
tar xf v${shapeit4_version}.tar.gz && \
rm v${shapeit4_version}.tar.gz && \
cd shapeit4-${shapeit4_version} && \
sed -i s^HTSLIB_INC=\$\(HOME\)/Tools/htslib-1.9^HTSLIB_INC=/usr/local/include/htslib^ makefile && \
sed -i s^HTSLIB_LIB=\$\(HOME\)/Tools/htslib-1.9/libhts.a^HTSLIB_LIB=/usr/local/lib/libhts.a^ makefile && \
sed -i s^HTSLIB_INC=\$\(HOME\)/Tools/htslib-1.11^HTSLIB_INC=/usr/local/include/htslib^ makefile && \
sed -i s^HTSLIB_LIB=\$\(HOME\)/Tools/htslib-1.11/libhts.a^HTSLIB_LIB=/usr/local/lib/libhts.a^ makefile && \
sed -i s^BOOST_INC=/usr/include^BOOST_INC=/usr/local/include/boost/^ makefile && \
sed -i s^BOOST_INC=/usr/include^BOOST_INC=/usr/local/include/boost/^ makefile && \
sed -i s^BOOST_LIB_IO=/usr/lib/x86_64-linux-gnu/libboost_iostreams.a^BOOST_LIB_IO=/usr/local/lib/libboost_iostreams.a^ makefile && \
sed -i s^BOOST_LIB_PO=/usr/lib/x86_64-linux-gnu/libboost_program_options.a^BOOST_LIB_PO=/usr/local/lib/libboost_program_options.a^ makefile && \
make && \
cp bin/shapeit4 /usr/local/bin
cp /tmp/shapeit4-${shapeit4_version}/bin/shapeit4.2 /usr/local/bin/shapeit4

WORKDIR /usr/local/bin

6 changes: 3 additions & 3 deletions tasks/gcp/StatisticalPhasingTasks.wdl
Original file line number Diff line number Diff line change
Expand Up @@ -51,15 +51,15 @@ task ShapeIt4 {
# TODO - how to handle refence as an option
ReferenceSequence? reference

String docker_tag = "us.gcr.io/broad-gotc-prod/malariagen/shapeit4:4.1.3"
String docker_tag = "us.gcr.io/broad-gotc-prod/malariagen/shapeit4:4.2.1"
# Compute Engine always stops preemptible instances after they run for 24 hours
Int preemptible_tries = 0
Int preemptible_tries = 2
Int num_cpu = 4
Float mem_gb = 15
RunTimeSettings runTimeSettings
}

Int disk_size = ceil(size(merged_vcf, "GiB") + size(merged_vcf_index, "GiB") + size(genetic_map, "GiB")) * 20 + 20
Int disk_size = ceil(size(merged_vcf, "GiB") + size(merged_vcf_index, "GiB") + size(genetic_map, "GiB")) * 5 + 20
String output_prefix = sub(region, ":", "_")
String output_filename = output_prefix + "_" + project_id + "_phased.vcf.gz"

Expand Down

0 comments on commit f846808

Please sign in to comment.