Skip to content
This repository has been archived by the owner on Apr 19, 2023. It is now read-only.

Commit

Permalink
Update Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
a3sha2 committed Jun 13, 2020
1 parent 3ecf205 commit 3c9316e
Showing 1 changed file with 14 additions and 24 deletions.
38 changes: 14 additions & 24 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,8 @@ RUN pip install --no-cache-dir nipype nibabel niworkflows nilearn matplotlib
RUN rm -rf ~/.cache/pip/* && sync
RUN apt-get update

ENV FSLDIR="/opt/fsl-5.0.10" \
PATH="/opt/fsl-5.0.10/bin:$PATH"
RUN apt-get update -qq \
&& apt-get install -y -q --no-install-recommends \
bc \
Expand All @@ -83,29 +85,17 @@ RUN apt-get update -qq \
libxt6 \
wget \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*

ENV FSLDIR="/opt/fsl-6.0.3" \
PATH="/opt/fsl-6.0.3/bin:$PATH"

RUN echo "Downloading FSL ..." \
&& mkdir -p /opt/fsl-6.0.3 \
&& curl -fsSL --retry 5 https://fsl.fmrib.ox.ac.uk/fsldownloads/fsl-6.0.3-centos6_64.tar.gz \
| tar -xz -C /opt/fsl-6.0.3 --strip-components 1 \
--exclude='fsl/doc' \
--exclude='fsl/data/atlases' \
--exclude='fsl/data/possum' \
--exclude='fsl/src' \
--exclude='fsl/extras/src' \
--exclude='fsl/bin/fslview*' \
--exclude='fsl/bin/FSLeyes' \
&& echo "Installing FSL conda environment ..." \
&& sed -i -e "/fsleyes/d" -e "/wxpython/d" \
${FSLDIR}/etc/fslconf/fslpython_environment.yml \
&& bash /opt/fsl-6.0.3/etc/fslconf/fslpython_install.sh -f /opt/fsl-6.0.3 \
&& find ${FSLDIR}/fslpython/envs/fslpython/lib/python3.7/site-packages/ -type d -name "tests" -print0 | xargs -0 rm -r \
&& ${FSLDIR}/fslpython/bin/conda clean --all

&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* \
&& echo "Downloading FSL ..." \
&& mkdir -p /opt/fsl-5.0.10 \
&& curl -fsSL --retry 5 https://fsl.fmrib.ox.ac.uk/fsldownloads/fsl-5.0.10-centos6_64.tar.gz \
| tar -xz -C /opt/fsl-5.0.10 --strip-components 1 \
&& sed -i '$iecho Some packages in this Docker container are non-free' $ND_ENTRYPOINT \
&& sed -i '$iecho If you are considering commercial use of this container, please consult the relevant license:' $ND_ENTRYPOINT \
&& sed -i '$iecho https://fsl.fmrib.ox.ac.uk/fsl/fslwiki/Licence' $ND_ENTRYPOINT \
&& sed -i '$isource $FSLDIR/etc/fslconf/fsl.sh' $ND_ENTRYPOINT \
&& echo "Installing FSL conda environment ..." \
&& bash /opt/fsl-5.0.10/etc/fslconf/fslpython_install.sh -f /opt/fsl-5.0.10

ENV C3DPATH="/opt/convert3d-1.0.0" \
PATH="/opt/convert3d-1.0.0/bin:$PATH"
Expand Down Expand Up @@ -239,7 +229,7 @@ RUN bash -c \
&& rm i30llenk6s37kv8nkqxgulwylaxp928g.xz'


RUN bash -c 'BRAINATLAS=/xcpEngine/atlas BRAINSPACE=/xcpEngine/space XCPEDIR=/xcpEngine FSLDIR=/opt/fsl-6.0.3 AFNI_PATH=/opt/afni-latest C3D_PATH=/opt/convert3d-nightly/bin ANTSPATH=/opt/ants-latest/bin /xcpEngine/xcpReset \
RUN bash -c 'BRAINATLAS=/xcpEngine/atlas BRAINSPACE=/xcpEngine/space XCPEDIR=/xcpEngine FSLDIR=/opt/fsl-5.0.10 AFNI_PATH=/opt/afni-latest C3D_PATH=/opt/convert3d-nightly/bin ANTSPATH=/opt/ants-latest/bin /xcpEngine/xcpReset \
&& BRAINATLAS=/xcpEngine/atlas BRAINSPACE=/xcpEngine/space XCPEDIR=/xcpEngine /xcpEngine/utils/repairMetadata'

RUN bash -c 'echo R_ENVIRON_USER\="" >> /usr/lib/R/etc/Renviron \
Expand Down

0 comments on commit 3c9316e

Please sign in to comment.