Skip to content
Snippets Groups Projects
Commit 6eda5029 authored by Mattia Mancini's avatar Mattia Mancini
Browse files

Updated dockerfiles

parent 44a78c18
No related branches found
No related tags found
1 merge request!69Change the name of the pre-calibrated output MS
Pipeline #162 failed
#!/bin/bash
set -e
. /opt/lofarsoft/lofarinit.sh
exec "$@"
FROM lofaruser/imaging-pipeline
FROM kernsuite/base:4 as builder
SHELL ["/bin/bash", "-c"]
RUN export DEBIAN_FRONTEND=noninteractive && \
apt-get update && \
apt-get install -y \
casacore-data \
casacore-dev \
libboost-python-dev \
libcfitsio-dev \
python-dev \
python3-numpy \
cmake \
build-essential \
libhdf5-serial-dev \
libarmadillo-dev \
lofar-dev \
libboost-filesystem-dev \
libboost-system-dev \
libboost-date-time-dev \
libboost-signals-dev \
libboost-program-options-dev \
libboost-test-dev \
libxml2-dev \
libpng-dev \
pkg-config \
aoflagger-dev \
libgtkmm-3.0-dev \
git \
wget \
libfftw3-dev
RUN mkdir -p /src/
WORKDIR /src/
# Build the IDG version from source
ADD ./idg /src/idg/src
RUN mkdir idg/build && cd idg/build && cmake -DCMAKE_INSTALL_PREFIX=/usr/local/ ../src && make install -j2
ADD ./DP3 /src/dp3/src
RUN cd /src/dp3/ && \
mkdir build && \
cd build && \
cmake ../src -DCMAKE_INSTALL_PREFIX=/usr/local/ &&\
make -j2 && \
make install -j2
#----------------------------------------------
FROM kernsuite/base:4 as runner
COPY --from=builder /usr/local/ /usr/local
SHELL ["/bin/bash", "-c"]
RUN export DEBIAN_FRONTEND=noninteractive && \
apt-get update && \
apt-get install -y \
aoflagger \
casacore-data \
libarmadillo8 \
libboost-date-time1.65.1 \
libboost-filesystem1.65.1 \
libboost-python1.65.1 \
libboost-program-options1.65.1 \
libboost-system1.65.1 \
libboost-signals1.65.1 \
libboost-test1.65.1 \
libcfitsio5 \
libgtkmm-3.0 \
libfftw3-3 \
libhdf5-cpp-100 \
libpng16-16 \
libstationresponse0 \
libxml2 \
python3 \
python3-casacore \
python3-numpy
RUN mkdir /home/lofaruser/ && \
groupadd -r lofaruser && \
useradd --no-log-init -r -g lofaruser lofaruser && \
chown lofaruser:lofaruser /home/lofaruser
ARG LSMTool_TAG=master
RUN apt-get update && apt-get install -y nodejs python3-pip git wsclean
RUN python3 -m pip install cwltool cwl-runner git+https://github.com/darafferty/LSMTool
RUN python3 -m pip install cwltool cwl-runner -e "git://github.com/darafferty/LSMTool.git@${LSMTool_TAG}#egg=LSMTool"
ADD L570745_uv_first10.MS.tar.xz /data
ADD skymodels.tar.gz /data/skymodels
......@@ -21,3 +102,9 @@ RUN chmod +rx /usr/local/bin/*
ENV PYTHONPATH="/usr/local/bin:${PYTHONPATH}"
ENTRYPOINT ["/home/lofaruser/.entrypoint"]
USER lofaruser
ARG IDG_TAG=master
LABEL IDG.version.tag=${IDG_TAG}
ARG DP3_TAG=master
LABEL DP3.version.tag=${DP3_TAG}
#! /bin/bash
set -e
git_clone_or_pull () {
REPO=$1
BRANCH=$2
DIR=$3
git clone -single-branch -b "${BRANCH}" "${REPO}" "${DIR}" 2> /dev/null || git -C "${DIR}" pull
}
# SOFTWARE VERSIONS
DP3_TAG=v4.1
IDG_TAG=0.6
LSMTool_TAG=v1.4.2
# FETCHES THE IDG
git_clone_or_pull https://gitlab.com/astron-idg/idg/ ${IDG_TAG} idg
# FETCHES DP3
git_clone_or_pull https://github.com/lofar-astron/DP3 ${DP3_TAG} DP3
# FETCHES THE SCRIPTS ONLY
BRANCH=production
REPO_URL=https://github.com/lofar-astron/prefactor
# FETCHES THE SCRIPTS ONLY
svn checkout ${REPO_URL}/branches/${BRANCH}/scripts
SCRIPT_PATH=$(realpath ${BASH_SOURCE[0]})
DOCKER_PATH=$(dirname ${SCRIPT_PATH})
docker build ${DOCKER_PATH} -t prefactor:latest
docker build ${DOCKER_PATH} --build-arg=IDG_TAG=${IDG_TAG} --build-arg=DP3_TAG=${DP3_TAG} --build-arg=LSMTool_TAG=${LSMTool_TAG} -t lofareosc/prefactor-ci
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment