Show More
@@ -1,46 +1,46 b'' | |||
|
1 | 1 | # Designed to be run as |
|
2 | 2 | # |
|
3 | 3 | # docker run -it -p 9999:8888 ipython/latest |
|
4 | 4 | |
|
5 | 5 | FROM ipython/scipystack |
|
6 | 6 | |
|
7 | 7 | MAINTAINER IPython Project <ipython-dev@scipy.org> |
|
8 | 8 | |
|
9 | 9 | # Can't directly add the source as it won't have the submodules |
|
10 | RUN mkdir /srv/ | |
|
10 | RUN mkdir -p /srv/ | |
|
11 | 11 | WORKDIR /srv/ |
|
12 | 12 | RUN git clone --recursive https://github.com/ipython/ipython.git |
|
13 | 13 | WORKDIR /srv/ipython/ |
|
14 | 14 | |
|
15 | 15 | # Installing certain dependencies directly |
|
16 | 16 | RUN pip2 install fabric |
|
17 | 17 | RUN pip3 install jsonschema jsonpointer fabric |
|
18 | 18 | |
|
19 | 19 | RUN python setup.py submodule |
|
20 | 20 | |
|
21 | 21 | # .[all] only works with -e |
|
22 | 22 | # Can't use -e because ipython2 and ipython3 will clobber each other |
|
23 | 23 | RUN pip2 install . |
|
24 | 24 | RUN pip3 install . |
|
25 | 25 | |
|
26 | 26 | EXPOSE 8888 |
|
27 | 27 | |
|
28 | 28 | # Generate a wrapper script |
|
29 | 29 | RUN echo "#!/bin/bash\nipython3 notebook --no-browser --port 8888 --ip=0.0.0.0" > /usr/local/bin/notebook.sh |
|
30 | 30 | RUN chmod a+x /usr/local/bin/notebook.sh |
|
31 | 31 | |
|
32 | 32 | # jupyter is our user |
|
33 | 33 | RUN useradd -m -s /bin/bash jupyter |
|
34 | 34 | |
|
35 | 35 | USER jupyter |
|
36 | 36 | ENV HOME /home/jupyter |
|
37 | 37 | ENV SHELL /bin/bash |
|
38 | 38 | ENV USER jupyter |
|
39 | 39 | |
|
40 | 40 | WORKDIR /home/jupyter/ |
|
41 | 41 | |
|
42 | 42 | # Register each kernel (Python 2.7.x, Python 3.4.x) |
|
43 | 43 | RUN ipython2 kernelspec install-self |
|
44 | 44 | RUN ipython3 kernelspec install-self |
|
45 | 45 | |
|
46 | 46 | CMD ["/usr/local/bin/notebook.sh"] |
General Comments 0
You need to be logged in to leave comments.
Login now