Skip to content

Commit 1009be2

Browse files
trsticklandTim Stickland
andauthored
Docker build fixes & perl locale fix (#89)
* updated Docker build to fix perl locale problem * found dependency issues that had broken the Docker build so fixed them too * changed the build so example FASTA files are copied from the repo where the docker build is done (so that if these files are changed in a branch/tag, that's reflected in the image that is built rather than always referring back to the master branch on github) * remove path-help email from Dockerfile, in line with PR #88 Co-authored-by: Tim Stickland <ts24@sanger.ac.uk>
1 parent 29bfe03 commit 1009be2

File tree

1 file changed

+21
-10
lines changed

1 file changed

+21
-10
lines changed

Dockerfile

Lines changed: 21 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,18 @@
11
#
22
# This container will allow you to run MSLT by blast against assemblies using the schemes from PubMLST
33
#
4-
FROM debian:testing
4+
FROM ubuntu:20.04
55

6-
#
7-
# Authorship
8-
#
9-
MAINTAINER ap13@sanger.ac.uk
6+
ARG DEBIAN_FRONTEND=noninteractive
7+
8+
RUN apt-get update -qq && \
9+
apt-get install -y locales && \
10+
sed -i -e 's/# \(en_GB\.UTF-8 .*\)/\1/' /etc/locale.gen && \
11+
touch /usr/share/locale/locale.alias && \
12+
locale-gen
13+
ENV LANG en_GB.UTF-8
14+
ENV LANGUAGE en_GB:en
15+
ENV LC_ALL en_GB.UTF-8
1016

1117
#
1218
# Set environment variables
@@ -16,12 +22,17 @@ ENV MLST_DATABASES /MLST_databases
1622
#
1723
# Update and Install dependencies
1824
#
19-
RUN apt-get update -qq && apt-get install -y wget ncbi-blast+ cpanminus gcc autoconf make libxml2-dev zlib1g zlib1g-dev libmodule-install-perl && cpanm -f Bio::MLST::Check
25+
RUN apt-get update -qq && \
26+
apt-get install -y wget ncbi-blast+ cpanminus gcc autoconf make libxml2-dev zlib1g zlib1g-dev libmodule-install-perl && \
27+
# expat required for current versions of various XML packages in CPAN
28+
apt-get install -y libexpat1-dev && \
29+
# there's a known issue with one of the tests in XML::DOM::XPath
30+
cpanm -notest XML::DOM::XPath && \
31+
# install CPAN modules without --force so errors aren't hidden
32+
cpanm Bio::MLST::Check
2033

21-
RUN mkdir -p /example && cd /example && \
22-
wget -O sample1.fa https://github.com/sanger-pathogens/mlst_check/raw/master/example/input_data/Salmonella_enterica_subsp_enterica_serovar_Typhi_str_CT18_v1.fa && \
23-
wget -O sample2.fa https://github.com/sanger-pathogens/mlst_check/raw/master/example/input_data/Salmonella_enterica_subsp_enterica_serovar_Typhimurium_DT104_v1.fa && \
24-
wget -O sample3.fa https://github.com/sanger-pathogens/mlst_check/raw/master/example/input_data/Salmonella_enterica_subsp_enterica_serovar_Weltevreden_str_10259_v0.2.fa
34+
# copy whatever example files are provided in the branch/tag that we're building from
35+
COPY ./example/input_data/*.fa /example/
2536

2637
#
2738
# Download the databases from PubMLST

0 commit comments

Comments
 (0)