1- # Generated by: Neurodocker version 0.7.0+0.gdc97516.dirty
2- # Latest release: Neurodocker version 0.7.0
3- # Timestamp: 2020/06/16 19:58:06 UTC
4- #
5- # Thank you for using Neurodocker. If you discover any issues
6- # or ways to improve this software, please submit an issue or
7- # pull request on our GitHub repository:
8- #
9- # https://github.com/ReproNim/neurodocker
10-
11- FROM neurodebian:stretch-non-free
12-
13- USER root
14-
15- ARG DEBIAN_FRONTEND="noninteractive"
1+ # Generated by Neurodocker and Reproenv.
162
3+ FROM neurodebian:bookworm-non-free
174ENV LANG="en_US.UTF-8" \
185 LC_ALL="en_US.UTF-8" \
196 ND_ENTRYPOINT="/neurodocker/startup.sh"
@@ -26,7 +13,6 @@ RUN export ND_ENTRYPOINT="/neurodocker/startup.sh" \
2613 curl \
2714 locales \
2815 unzip \
29- && apt-get clean \
3016 && rm -rf /var/lib/apt/lists/* \
3117 && sed -i -e 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' /etc/locale.gen \
3218 && dpkg-reconfigure --frontend=noninteractive locales \
@@ -40,156 +26,235 @@ RUN export ND_ENTRYPOINT="/neurodocker/startup.sh" \
4026 && echo 'if [ -n "$1" ]; then "$@"; else /usr/bin/env bash; fi' >> "$ND_ENTRYPOINT" ; \
4127 fi \
4228 && chmod -R 777 /neurodocker && chmod a+s /neurodocker
43-
44- ENTRYPOINT ["/neurodocker/startup.sh" ]
45-
4629ENV LANG="C.UTF-8"
47-
4830ENV LC_ALL="C.UTF-8"
49-
5031RUN apt-get update -qq \
51- && apt-get install -y -q --no-install-recommends \
52- pigz \
53- && apt-get clean \
54- && rm -rf /var/lib/apt/lists/*
55-
56- RUN mkdir -p /opt/dcm2niix && cd /opt/dcm2niix && curl -sSLO https://github.com/rordenlab/dcm2niix/releases/download/v1.0.20181125/dcm2niix_25-Nov-2018_lnx.zip && unzip dcm2niix_25-Nov-2018_lnx.zip && rm dcm2niix_25-Nov-2018_lnx.zip
57-
32+ && apt-get install -y -q --no-install-recommends \
33+ pigz \
34+ && rm -rf /var/lib/apt/lists/*
35+ RUN mkdir -p /opt/dcm2niix && cd /opt/dcm2niix && curl -sSLO https://github.com/rordenlab/dcm2niix/releases/download/v1.0.20250506/dcm2niix_lnx.zip && unzip dcm2niix_lnx.zip && rm dcm2niix_lnx.zip
5836ENV PATH="/opt/dcm2niix:$PATH"
59-
60- RUN test "$(getent passwd coder)" || useradd --no-user-group --create-home --shell /bin/bash coder
37+ RUN test "$(getent passwd coder)" \
38+ || useradd --no-user-group --create-home --shell /bin/bash coder
6139USER coder
62-
63- COPY ["." , "/home/coder/project" ]
64-
40+ COPY ["." , \
41+ "/home/coder/project" ]
6542USER root
66-
6743RUN chown -R coder /home/coder/project
68-
69- USER coder
70-
7144WORKDIR /home/coder
72-
73- SHELL [ "/bin/bash" , "--login" , "-c" ]
74-
45+ ENV SHELL= "/bin/bash"
46+ ENV CONDA_PLUGINS_AUTO_ACCEPT_TOS= "true"
47+ USER root
7548ENV CONDA_DIR="/opt/miniconda-latest" \
7649 PATH="/opt/miniconda-latest/bin:$PATH"
77- RUN export PATH="/opt/miniconda-latest/bin:$PATH" \
50+ RUN apt-get update -qq \
51+ && apt-get install -y -q --no-install-recommends \
52+ bzip2 \
53+ ca-certificates \
54+ curl \
55+ && rm -rf /var/lib/apt/lists/* \
56+ # Install dependencies.
57+ && export PATH="/opt/miniconda-latest/bin:$PATH" \
7858 && echo "Downloading Miniconda installer ..." \
7959 && conda_installer="/tmp/miniconda.sh" \
80- && curl -fsSL --retry 5 - o "$conda_installer" https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh \
60+ && curl -fsSL -o "$conda_installer" https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh \
8161 && bash "$conda_installer" -b -p /opt/miniconda-latest \
8262 && rm -f "$conda_installer" \
8363 && conda update -yq -nbase conda \
64+ # Prefer packages in conda-forge
8465 && conda config --system --prepend channels conda-forge \
66+ # Packages in lower-priority channels not considered if a package with the same
67+ # name exists in a higher priority channel. Can dramatically speed up installations.
68+ # Conda recommends this as a default
69+ # https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-channels.html
70+ && conda config --set channel_priority strict \
8571 && conda config --system --set auto_update_conda false \
8672 && conda config --system --set show_channel_urls true \
87- && sync && conda clean -y --all && sync \
88- && conda create -y -q --name neuro \
89- && conda install -y -q --name neuro \
90- "python=2.7" \
91- && sync && conda clean -y --all && sync \
92- && sed -i '$isource activate neuro' $ND_ENTRYPOINT
93-
94- # make conda activate command available from /bin/bash --login shells
73+ # Enable `conda activate`
74+ && conda init bash \
75+ && conda create -y --name neuro \
76+ && conda install -y --name neuro \
77+ "python=3.13" \
78+ # Clean up
79+ && sync && conda clean --all --yes && sync \
80+ && rm -rf ~/.cache/pip/*
81+ USER coder
9582RUN echo ". $CONDA_DIR/etc/profile.d/conda.sh" >> ~/.profile
96-
97- RUN conda init bash
98-
99- RUN conda activate neuro && pip install -e /home/coder/project/[test]
100-
10183USER root
102-
84+ RUN bash -c 'source "${CONDA_DIR}/etc/profile.d/conda.sh" && conda activate neuro && pip install --no-cache-dir -e /home/coder/project/[test]'
85+ ENV PATH="/opt/miniconda-latest/envs/neuro/bin:/home/coder/.local/bin:$PATH"
10386ENTRYPOINT ["/neurodocker/startup.sh" , "xnat_downloader" ]
10487
105- RUN echo '{ \
106- \n "pkg_manager": "apt", \
107- \n "instructions": [ \
108- \n [ \
109- \n "base", \
110- \n "neurodebian:stretch-non-free" \
111- \n ], \
112- \n [ \
113- \n "env", \
114- \n { \
115- \n "LANG": "C.UTF-8" \
116- \n } \
117- \n ], \
118- \n [ \
119- \n "env", \
120- \n { \
121- \n "LC_ALL": "C.UTF-8" \
122- \n } \
123- \n ], \
124- \n [ \
125- \n "install", \
126- \n [ \
127- \n "pigz" \
128- \n ] \
129- \n ], \
130- \n [ \
131- \n "run", \
132- \n "mkdir -p /opt/dcm2niix && cd /opt/dcm2niix && curl -sSLO https://github.com/rordenlab/dcm2niix/releases/download/v1.0.20181125/dcm2niix_25-Nov-2018_lnx.zip && unzip dcm2niix_25-Nov-2018_lnx.zip && rm dcm2niix_25-Nov-2018_lnx.zip" \
133- \n ], \
134- \n [ \
135- \n "env", \
136- \n { \
137- \n "PATH": "/opt/dcm2niix:$PATH" \
138- \n } \
139- \n ], \
140- \n [ \
141- \n "user", \
142- \n "coder" \
143- \n ], \
144- \n [ \
145- \n "copy", \
146- \n [ \
147- \n ".", \
148- \n "/home/coder/project" \
149- \n ] \
150- \n ], \
151- \n [ \
152- \n "user", \
153- \n "root" \
154- \n ], \
155- \n [ \
156- \n "run", \
157- \n "chown -R coder /home/coder/project" \
158- \n ], \
159- \n [ \
160- \n "user", \
161- \n "coder" \
162- \n ], \
163- \n [ \
164- \n "workdir", \
165- \n "/home/coder" \
166- \n ], \
167- \n [ \
168- \n "env", \
169- \n { \
170- \n "SHELL": "/bin/bash" \
171- \n } \
172- \n ], \
173- \n [ \
174- \n "miniconda", \
175- \n { \
176- \n "create_env": "neuro", \
177- \n "conda_install": [ \
178- \n "python=2.7" \
179- \n ] \
180- \n } \
181- \n ], \
182- \n [ \
183- \n "run", \
184- \n "conda init && . /home/coder/.bashrc && . activate neuro && pip install -e /home/coder/project/[test]" \
185- \n ], \
186- \n [ \
187- \n "user", \
188- \n "root" \
189- \n ], \
190- \n [ \
191- \n "entrypoint", \
192- \n "xnat_downloader" \
193- \n ] \
194- \n ] \
195- \n }' > /neurodocker/neurodocker_specs.json
88+ # Save specification to JSON.
89+ RUN printf '{ \
90+ "pkg_manager": "apt", \
91+ "existing_users": [ \
92+ "root" \
93+ ], \
94+ "instructions": [ \
95+ { \
96+ "name": "from_", \
97+ "kwds": { \
98+ "base_image": "neurodebian:bookworm-non-free" \
99+ } \
100+ }, \
101+ { \
102+ "name": "env", \
103+ "kwds": { \
104+ "LANG": "en_US.UTF-8", \
105+ "LC_ALL": "en_US.UTF-8", \
106+ "ND_ENTRYPOINT": "/neurodocker/startup.sh" \
107+ } \
108+ }, \
109+ { \
110+ "name": "run", \
111+ "kwds": { \
112+ "command": "export ND_ENTRYPOINT=\\ "/neurodocker/startup.sh\\ "\\ napt-get update -qq\\ napt-get install -y -q --no-install-recommends \\\\\\ n apt-utils \\\\\\ n bzip2 \\\\\\ n ca-certificates \\\\\\ n curl \\\\\\ n locales \\\\\\ n unzip\\ nrm -rf /var/lib/apt/lists/*\\ nsed -i -e ' "'" 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' "'" ' /etc/locale.gen\\ ndpkg-reconfigure --frontend=noninteractive locales\\ nupdate-locale LANG=\\ "en_US.UTF-8\\ "\\ nchmod 777 /opt && chmod a+s /opt\\ nmkdir -p /neurodocker\\ nif [ ! -f \\ "$ND_ENTRYPOINT\\ " ]; then\\ n echo ' "'" '#!/usr/bin/env bash' "'" ' >> \\ "$ND_ENTRYPOINT\\ "\\ n echo ' "'" 'set -e' "'" ' >> \\ "$ND_ENTRYPOINT\\ "\\ n echo ' "'" 'export USER=\\ "${USER:=`whoami`}\\ "' "'" ' >> \\ "$ND_ENTRYPOINT\\ "\\ n echo ' "'" 'if [ -n \\ "$1\\ " ]; then \\ "$@\\ "; else /usr/bin/env bash; fi' "'" ' >> \\ "$ND_ENTRYPOINT\\ ";\\ nfi\\ nchmod -R 777 /neurodocker && chmod a+s /neurodocker" \
113+ } \
114+ }, \
115+ { \
116+ "name": "env", \
117+ "kwds": { \
118+ "LANG": "C.UTF-8" \
119+ } \
120+ }, \
121+ { \
122+ "name": "env", \
123+ "kwds": { \
124+ "LC_ALL": "C.UTF-8" \
125+ } \
126+ }, \
127+ { \
128+ "name": "install", \
129+ "kwds": { \
130+ "pkgs": [ \
131+ "pigz" \
132+ ], \
133+ "opts": null \
134+ } \
135+ }, \
136+ { \
137+ "name": "run", \
138+ "kwds": { \
139+ "command": "apt-get update -qq \\\\\\ n && apt-get install -y -q --no-install-recommends \\\\\\ n pigz \\\\\\ n && rm -rf /var/lib/apt/lists/*" \
140+ } \
141+ }, \
142+ { \
143+ "name": "run", \
144+ "kwds": { \
145+ "command": "mkdir -p /opt/dcm2niix && cd /opt/dcm2niix && curl -sSLO https://github.com/rordenlab/dcm2niix/releases/download/v1.0.20250506/dcm2niix_lnx.zip && unzip dcm2niix_lnx.zip && rm dcm2niix_lnx.zip" \
146+ } \
147+ }, \
148+ { \
149+ "name": "env", \
150+ "kwds": { \
151+ "PATH": "/opt/dcm2niix:$PATH" \
152+ } \
153+ }, \
154+ { \
155+ "name": "user", \
156+ "kwds": { \
157+ "user": "coder" \
158+ } \
159+ }, \
160+ { \
161+ "name": "copy", \
162+ "kwds": { \
163+ "source": [ \
164+ ".", \
165+ "/home/coder/project" \
166+ ], \
167+ "destination": "/home/coder/project" \
168+ } \
169+ }, \
170+ { \
171+ "name": "user", \
172+ "kwds": { \
173+ "user": "root" \
174+ } \
175+ }, \
176+ { \
177+ "name": "run", \
178+ "kwds": { \
179+ "command": "chown -R coder /home/coder/project" \
180+ } \
181+ }, \
182+ { \
183+ "name": "workdir", \
184+ "kwds": { \
185+ "path": "/home/coder" \
186+ } \
187+ }, \
188+ { \
189+ "name": "env", \
190+ "kwds": { \
191+ "SHELL": "/bin/bash" \
192+ } \
193+ }, \
194+ { \
195+ "name": "env", \
196+ "kwds": { \
197+ "CONDA_PLUGINS_AUTO_ACCEPT_TOS": "true" \
198+ } \
199+ }, \
200+ { \
201+ "name": "user", \
202+ "kwds": { \
203+ "user": "root" \
204+ } \
205+ }, \
206+ { \
207+ "name": "env", \
208+ "kwds": { \
209+ "CONDA_DIR": "/opt/miniconda-latest", \
210+ "PATH": "/opt/miniconda-latest/bin:$PATH" \
211+ } \
212+ }, \
213+ { \
214+ "name": "run", \
215+ "kwds": { \
216+ "command": "apt-get update -qq\\napt-get install -y -q --no-install-recommends \\\\\\n bzip2 \\\\\\n ca-certificates \\\\\\n curl\\nrm -rf /var/lib/apt/lists/*\\n# Install dependencies.\\nexport PATH=\\"/opt/miniconda-latest/bin:$PATH\\"\\necho \\"Downloading Miniconda installer ...\\"\\nconda_installer=\\"/tmp/miniconda.sh\\"\\ncurl -fsSL -o \\"$conda_installer\\" https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh\\nbash \\"$conda_installer\\" -b -p /opt/miniconda-latest\\nrm -f \\"$conda_installer\\"\\nconda update -yq -nbase conda\\n# Prefer packages in conda-forge\\nconda config --system --prepend channels conda-forge\\n# Packages in lower-priority channels not considered if a package with the same\\n# name exists in a higher priority channel. Can dramatically speed up installations.\\n# Conda recommends this as a default\\n# https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-channels.html\\nconda config --set channel_priority strict\\nconda config --system --set auto_update_conda false\\nconda config --system --set show_channel_urls true\\n# Enable `conda activate`\\nconda init bash\\nconda create -y --name neuro\\nconda install -y --name neuro \\\\\\n \\"python=3.13\\"\\n# Clean up\\nsync && conda clean --all --yes && sync\\nrm -rf ~/.cache/pip/*" \
217+ } \
218+ }, \
219+ { \
220+ "name": "user", \
221+ "kwds": { \
222+ "user": "coder" \
223+ } \
224+ }, \
225+ { \
226+ "name": "run", \
227+ "kwds": { \
228+ "command": "echo \\ ". $CONDA_DIR/etc/profile.d/conda.sh\\ " >> ~/.profile" \
229+ } \
230+ }, \
231+ { \
232+ "name": "user", \
233+ "kwds": { \
234+ "user": "root" \
235+ } \
236+ }, \
237+ { \
238+ "name": "run", \
239+ "kwds": { \
240+ "command": "bash -c ' "'" 'source \\ "${CONDA_DIR}/etc/profile.d/conda.sh\\ " && conda activate neuro && pip install --no-cache-dir -e /home/coder/project/[test]' "'" '" \
241+ } \
242+ }, \
243+ { \
244+ "name": "env", \
245+ "kwds": { \
246+ "PATH": "/opt/miniconda-latest/envs/neuro/bin:/home/coder/.local/bin:$PATH" \
247+ } \
248+ }, \
249+ { \
250+ "name": "entrypoint", \
251+ "kwds": { \
252+ "args": [ \
253+ "/neurodocker/startup.sh", \
254+ "xnat_downloader" \
255+ ] \
256+ } \
257+ } \
258+ ] \
259+ }' > /.reproenv.json
260+ # End saving to specification to JSON.
0 commit comments