-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
57 lines (48 loc) · 1.64 KB
/
Dockerfile
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
FROM neurodebian:trusty
# Add dcm2niix and lbgdcm (taken from scitran dcm2niix dockerfile)
RUN apt-get update -qq \
&& apt-get install -y \
git \
curl \
build-essential \
cmake \
pkg-config \
libgdcm-tools=2.2.4-1.1ubuntu4 \
bsdtar \
unzip \
pigz \
gzip \
wget \
jq \
libgl1-mesa-glx
# Compile DCM2NIIX from source (latest commit as of Sept. 1, 2017)
ENV DCMCOMMIT=988d16b7327028d46ed7f45f00cc704254a91446
RUN curl -#L https://github.com/rordenlab/dcm2niix/archive/$DCMCOMMIT.zip | bsdtar -xf- -C /usr/local
WORKDIR /usr/local/dcm2niix-${DCMCOMMIT}/build
RUN cmake -DUSE_OPENJPEG=ON ../ && \
make && \
make install
# Install and setup miniconda (taken from mriqc Dockerfile)
RUN curl -sSLO https://repo.continuum.io/miniconda/Miniconda3-4.3.21-Linux-x86_64.sh && \
bash Miniconda3-4.3.21-Linux-x86_64.sh -b -p /usr/local/miniconda && \
rm Miniconda3-4.3.21-Linux-x86_64.sh
ENV PATH=/usr/local/miniconda/bin:$PATH \
LANG=C.UTF-8 \
LC_ALL=C.UTF-8
RUN conda install -y \
numpy==1.13.1 \
matplotlib==2.0.2 \
pandas==0.20.3; \
sync && \
chmod +x /usr/local/miniconda/bin/* && \
conda clean --all -y; sync && \
python -c "from matplotlib import font_manager" && \
sed -i 's/\(backend *: \).*$/\1Agg/g' $( python -c "import matplotlib; print(matplotlib.matplotlib_fname())" )
WORKDIR /usr/local/src/fmrif_tools
COPY . /usr/local/src/fmrif_tools
RUN cd /usr/local/src/fmrif_tools && \
pip install -r docker_requirements.txt && \
pip install . && \
rm -rf ~/.cache/pip
RUN ldconfig
ENTRYPOINT ["/usr/local/miniconda/bin/oxy2bids"]