-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathDockerfile.snptest
35 lines (27 loc) · 1.03 KB
/
Dockerfile.snptest
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# SPDX-License-Identifier: GPL-2.0
ARG BASE
FROM $BASE
# build-args
ARG BASE
ARG RUN_CMD
ARG BUILD_REPO
WORKDIR /runtime
ARG SNPTEST_URL="https://www.well.ox.ac.uk/~gav/resources/"
ARG SNPTEST_VER="snptest_v2.5.6"
ARG SNPTEST_ARCH="CentOS_Linux7.9.2009-x86_64_static"
ARG SNPTEST_TAR=${SNPTEST_VER}_${SNPTEST_ARCH}.tgz
ARG SNPTEST_DIR="/opt/bin"
RUN wget ${SNPTEST_URL}/${SNPTEST_TAR} && mkdir -p ${SNPTEST_DIR} && \
tar xvf $SNPTEST_TAR --strip-components=1 -C ${SNPTEST_DIR} && \
ln -s "${SNPTEST_DIR}/${SNPTEST_VER}" \
"${SNPTEST_DIR}/${RUN_CMD}" && rm $SNPTEST_TAR
ENV PATH=${SNPTEST_DIR}:${PATH}
ARG TEST="/test.sh"
COPY --chmod=0555 src/test/$RUN_CMD.sh ${TEST}
ARG ENTRY="/entrypoint.sh"
RUN echo "#!/bin/bash" > ${ENTRY} && echo "$RUN_CMD \$@" >> ${ENTRY} && \
chmod ugo+rx ${ENTRY}
ENTRYPOINT [ "/entrypoint.sh" ]
LABEL org.opencontainers.image.base.name="${BASE}"
LABEL org.opencontainers.image.description="SNPtest from https://www.well.ox.ac.uk/~gav/resources/"
LABEL org.opencontainers.image.url="${BUILD_REPO}"