Add Ipython (#1685)
This commit is contained in:
parent
85c57a0b6f
commit
29483bab8c
@ -717,9 +717,31 @@ services:
|
||||
volumes:
|
||||
- ${DATA_PATH_HOST}/portainer_data:/data
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
extra_hosts:
|
||||
- "dockerhost:${DOCKER_HOST_IP}"
|
||||
ports:
|
||||
- 9010:9000
|
||||
|
||||
### IPython #########################################
|
||||
ipython-controller:
|
||||
build:
|
||||
context: ./ipython
|
||||
dockerfile: Dockerfile.controller
|
||||
networks:
|
||||
- backend
|
||||
extra_hosts:
|
||||
- "laradock-ipython:${LARADOCK_IPYTHON_CONTROLLER_IP}"
|
||||
ports:
|
||||
- "33327-33338:33327-33338"
|
||||
ipython-engine:
|
||||
build:
|
||||
context: ./ipython
|
||||
dockerfile: Dockerfile.engine
|
||||
networks:
|
||||
- backend
|
||||
extra_hosts:
|
||||
- "laradock-ipython:${LARADOCK_IPYTHON_CONTROLLER_IP}"
|
||||
|
||||
### Docker-in-Docker ################################################
|
||||
docker-in-docker:
|
||||
image: docker:dind
|
||||
|
@ -360,6 +360,9 @@ SOLR_VERSION=5.5
|
||||
SOLR_PORT=8983
|
||||
SOLR_DATAIMPORTHANDLER_MYSQL=false
|
||||
|
||||
### IPYTHON ##################################################
|
||||
LARADOCK_IPYTHON_CONTROLLER_IP=127.0.0.1
|
||||
|
||||
### NETDATA ###############################################
|
||||
NETDATA_PORT=19999
|
||||
|
||||
|
17
ipython/Dockerfile.controller
Normal file
17
ipython/Dockerfile.controller
Normal file
@ -0,0 +1,17 @@
|
||||
FROM python:3.5-alpine
|
||||
|
||||
LABEL maintainer="ahkui <ahkui@outlook.com>"
|
||||
|
||||
USER root
|
||||
|
||||
RUN apk add --no-cache build-base
|
||||
|
||||
RUN python -m pip --quiet --no-cache-dir install \
|
||||
ipyparallel
|
||||
|
||||
RUN ipython profile create --parallel --profile=default
|
||||
|
||||
COPY ipcontroller-client.json /root/.ipython/profile_default/security/ipcontroller-client.json
|
||||
COPY ipcontroller-engine.json /root/.ipython/profile_default/security/ipcontroller-engine.json
|
||||
|
||||
CMD ["sh","-c","ipcontroller --ip=* --reuse"]
|
23
ipython/Dockerfile.engine
Normal file
23
ipython/Dockerfile.engine
Normal file
@ -0,0 +1,23 @@
|
||||
FROM python:3.5-alpine
|
||||
|
||||
LABEL maintainer="ahkui <ahkui@outlook.com>"
|
||||
|
||||
USER root
|
||||
|
||||
RUN apk add --no-cache build-base
|
||||
|
||||
RUN python -m pip --quiet --no-cache-dir install \
|
||||
ipyparallel \
|
||||
numpy \
|
||||
pandas \
|
||||
pymongo \
|
||||
redis \
|
||||
requests \
|
||||
bs4
|
||||
|
||||
RUN ipython profile create --parallel --profile=default
|
||||
|
||||
COPY ipcontroller-client.json /root/.ipython/profile_default/security/ipcontroller-client.json
|
||||
COPY ipcontroller-engine.json /root/.ipython/profile_default/security/ipcontroller-engine.json
|
||||
|
||||
CMD ["sh","-c","ipcluster engines"]
|
16
ipython/ipcontroller-client.json
Normal file
16
ipython/ipcontroller-client.json
Normal file
@ -0,0 +1,16 @@
|
||||
{
|
||||
"key": "868074dd-060311910ab3d6991611bccf",
|
||||
"signature_scheme": "hmac-sha256",
|
||||
"unpack": "json",
|
||||
"pack": "json",
|
||||
"ssh": "",
|
||||
"task_scheme": "leastload",
|
||||
"interface": "tcp://*",
|
||||
"location": "laradock-ipython",
|
||||
"notification": 33338,
|
||||
"iopub": 33337,
|
||||
"control": 33336,
|
||||
"mux": 33335,
|
||||
"task": 33334,
|
||||
"registration": 33333
|
||||
}
|
16
ipython/ipcontroller-engine.json
Normal file
16
ipython/ipcontroller-engine.json
Normal file
@ -0,0 +1,16 @@
|
||||
{
|
||||
"key": "868074dd-060311910ab3d6991611bccf",
|
||||
"signature_scheme": "hmac-sha256",
|
||||
"unpack": "json",
|
||||
"pack": "json",
|
||||
"ssh": "",
|
||||
"interface": "tcp://*",
|
||||
"location": "laradock-ipython",
|
||||
"iopub": 33327,
|
||||
"hb_ping": 33328,
|
||||
"hb_pong": 33329,
|
||||
"control": 33330,
|
||||
"mux": 33331,
|
||||
"task": 33332,
|
||||
"registration": 33333
|
||||
}
|
Loading…
Reference in New Issue
Block a user