Skip to content

Commit ee16a45

Browse files
committed
ENH: updates dockerfile
1 parent 6abc24f commit ee16a45

File tree

1 file changed

+33
-33
lines changed

1 file changed

+33
-33
lines changed

Dockerfile

Lines changed: 33 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
# pull request on our GitHub repository:
66
# https://github.com/kaczmarj/neurodocker
77
#
8-
# Timestamp: 2018-05-14 11:52:36
8+
# Timestamp: 2018-05-16 08:08:30
99

1010
FROM neurodebian:stretch-non-free
1111

@@ -126,43 +126,43 @@ RUN conda create -y -q --name neuro python=3.6 \
126126
&& sync \
127127
&& sed -i '$isource activate neuro' $ND_ENTRYPOINT
128128

129-
# User-defined BASH instruction
130-
RUN bash -c "source activate neuro && jupyter nbextension enable exercise2/main && jupyter nbextension enable spellchecker/main"
131-
132-
# User-defined BASH instruction
133-
RUN bash -c "mkdir -p ~/.jupyter && echo c.NotebookApp.ip = \\"0.0.0.0\\" > ~/.jupyter/jupyter_notebook_config.py"
129+
# User-defined instruction
130+
RUN source activate neuro && jupyter nbextension enable exercise2/main && jupyter nbextension enable spellchecker/main
134131

135132
USER root
136133

137-
# User-defined BASH instruction
138-
RUN bash -c "mkdir /data && chmod 777 /data && chmod a+s /data"
134+
# User-defined instruction
135+
RUN mkdir /data && chmod 777 /data && chmod a+s /data
139136

140-
# User-defined BASH instruction
141-
RUN bash -c "mkdir /output && chmod 777 /output && chmod a+s /output"
137+
# User-defined instruction
138+
RUN mkdir /output && chmod 777 /output && chmod a+s /output
142139

143140
USER neuro
144141

145-
# User-defined BASH instruction
146-
RUN bash -c "source activate neuro && cd /data && datalad install -r ///workshops/nih-2017/ds000114 && cd ds000114 && datalad update -r && datalad get -r sub-01/ses-test/anat sub-01/ses-test/func/*fingerfootlips*"
142+
# User-defined instruction
143+
RUN source activate neuro && cd /data && datalad install -r ///workshops/nih-2017/ds000114 && cd ds000114 && datalad update -r && datalad get -r sub-01/ses-test/anat sub-01/ses-test/func/*fingerfootlips*
147144

148-
# User-defined BASH instruction
149-
RUN bash -c "curl -L https://files.osf.io/v1/resources/fvuh8/providers/osfstorage/580705089ad5a101f17944a9 -o /data/ds000114/derivatives/fmriprep/mni_icbm152_nlin_asym_09c.tar.gz && tar xf /data/ds000114/derivatives/fmriprep/mni_icbm152_nlin_asym_09c.tar.gz -C /data/ds000114/derivatives/fmriprep/. && rm /data/ds000114/derivatives/fmriprep/mni_icbm152_nlin_asym_09c.tar.gz && find /data/ds000114/derivatives/fmriprep/mni_icbm152_nlin_asym_09c -type f -not -name ?mm_T1.nii.gz -not -name ?mm_brainmask.nii.gz -not -name ?mm_tpm*.nii.gz -delete"
145+
# User-defined instruction
146+
RUN curl -L https://files.osf.io/v1/resources/fvuh8/providers/osfstorage/580705089ad5a101f17944a9 -o /data/ds000114/derivatives/fmriprep/mni_icbm152_nlin_asym_09c.tar.gz && tar xf /data/ds000114/derivatives/fmriprep/mni_icbm152_nlin_asym_09c.tar.gz -C /data/ds000114/derivatives/fmriprep/. && rm /data/ds000114/derivatives/fmriprep/mni_icbm152_nlin_asym_09c.tar.gz && find /data/ds000114/derivatives/fmriprep/mni_icbm152_nlin_asym_09c -type f -not -name ?mm_T1.nii.gz -not -name ?mm_brainmask.nii.gz -not -name ?mm_tpm*.nii.gz -delete
150147

151148
COPY [".", "/home/neuro/nipype_tutorial"]
152149

153-
# User-defined BASH instruction
154-
RUN bash -c "printf \"[user]\n\tname = miykael\n\temail = michaelnotter@hotmail.com\n\" > ~/.gitconfig"
150+
# User-defined instruction
151+
RUN printf "[user]\n\tname = miykael\n\temail = michaelnotter@hotmail.com\n" > ~/.gitconfig
155152

156153
USER root
157154

158-
# User-defined BASH instruction
159-
RUN bash -c "chown -R neuro /home/neuro/nipype_tutorial"
155+
# User-defined instruction
156+
RUN chown -R neuro /home/neuro/nipype_tutorial
160157

161-
# User-defined BASH instruction
162-
RUN bash -c "rm -rf /opt/conda/pkgs/*"
158+
# User-defined instruction
159+
RUN rm -rf /opt/conda/pkgs/*
163160

164161
USER neuro
165162

163+
# User-defined instruction
164+
RUN mkdir -p ~/.jupyter && echo c.NotebookApp.ip = \"0.0.0.0\" > ~/.jupyter/jupyter_notebook_config.py
165+
166166
WORKDIR /home/neuro/nipype_tutorial
167167

168168
CMD ["jupyter-notebook"]
@@ -227,35 +227,31 @@ RUN echo '{ \
227227
\n } \
228228
\n ], \
229229
\n [ \
230-
\n "run_bash", \
230+
\n "run", \
231231
\n "source activate neuro && jupyter nbextension enable exercise2/main && jupyter nbextension enable spellchecker/main" \
232232
\n ], \
233233
\n [ \
234-
\n "run_bash", \
235-
\n "mkdir -p ~/.jupyter && echo c.NotebookApp.ip = \\\"0.0.0.0\\\" > ~/.jupyter/jupyter_notebook_config.py" \
236-
\n ], \
237-
\n [ \
238234
\n "user", \
239235
\n "root" \
240236
\n ], \
241237
\n [ \
242-
\n "run_bash", \
238+
\n "run", \
243239
\n "mkdir /data && chmod 777 /data && chmod a+s /data" \
244240
\n ], \
245241
\n [ \
246-
\n "run_bash", \
242+
\n "run", \
247243
\n "mkdir /output && chmod 777 /output && chmod a+s /output" \
248244
\n ], \
249245
\n [ \
250246
\n "user", \
251247
\n "neuro" \
252248
\n ], \
253249
\n [ \
254-
\n "run_bash", \
250+
\n "run", \
255251
\n "source activate neuro && cd /data && datalad install -r ///workshops/nih-2017/ds000114 && cd ds000114 && datalad update -r && datalad get -r sub-01/ses-test/anat sub-01/ses-test/func/*fingerfootlips*" \
256252
\n ], \
257253
\n [ \
258-
\n "run_bash", \
254+
\n "run", \
259255
\n "curl -L https://files.osf.io/v1/resources/fvuh8/providers/osfstorage/580705089ad5a101f17944a9 -o /data/ds000114/derivatives/fmriprep/mni_icbm152_nlin_asym_09c.tar.gz && tar xf /data/ds000114/derivatives/fmriprep/mni_icbm152_nlin_asym_09c.tar.gz -C /data/ds000114/derivatives/fmriprep/. && rm /data/ds000114/derivatives/fmriprep/mni_icbm152_nlin_asym_09c.tar.gz && find /data/ds000114/derivatives/fmriprep/mni_icbm152_nlin_asym_09c -type f -not -name ?mm_T1.nii.gz -not -name ?mm_brainmask.nii.gz -not -name ?mm_tpm*.nii.gz -delete" \
260256
\n ], \
261257
\n [ \
@@ -266,26 +262,30 @@ RUN echo '{ \
266262
\n ] \
267263
\n ], \
268264
\n [ \
269-
\n "run_bash", \
265+
\n "run", \
270266
\n "printf \"[user]\\\n\\tname = miykael\\\n\\temail = michaelnotter@hotmail.com\\\n\" > ~/.gitconfig" \
271267
\n ], \
272268
\n [ \
273269
\n "user", \
274270
\n "root" \
275271
\n ], \
276272
\n [ \
277-
\n "run_bash", \
273+
\n "run", \
278274
\n "chown -R neuro /home/neuro/nipype_tutorial" \
279275
\n ], \
280276
\n [ \
281-
\n "run_bash", \
277+
\n "run", \
282278
\n "rm -rf /opt/conda/pkgs/*" \
283279
\n ], \
284280
\n [ \
285281
\n "user", \
286282
\n "neuro" \
287283
\n ], \
288284
\n [ \
285+
\n "run", \
286+
\n "mkdir -p ~/.jupyter && echo c.NotebookApp.ip = \\\"0.0.0.0\\\" > ~/.jupyter/jupyter_notebook_config.py" \
287+
\n ], \
288+
\n [ \
289289
\n "workdir", \
290290
\n "/home/neuro/nipype_tutorial" \
291291
\n ], \
@@ -296,6 +296,6 @@ RUN echo '{ \
296296
\n ] \
297297
\n ] \
298298
\n ], \
299-
\n "generation_timestamp": "2018-05-14 11:52:36", \
299+
\n "generation_timestamp": "2018-05-16 08:08:30", \
300300
\n "neurodocker_version": "0.3.2" \
301301
\n}' > /neurodocker/neurodocker_specs.json

0 commit comments

Comments
 (0)