Commit d83541e8 authored by Rafal Skolasinski's avatar Rafal Skolasinski

add some missing files

parent a92592b5
Pipeline #4815 passed with stage
in 18 seconds
......@@ -42,11 +42,6 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
# Syncthing installation
RUN curl -s https://syncthing.net/release-key.txt | apt-key add - && \
echo "deb https://apt.syncthing.net/ syncthing stable" | tee /etc/apt/sources.list.d/syncthing.list && \
apt-get update && apt-get install -y syncthing syncthing-inotify && apt-get clean
# Install supervisor for automatic starting of syncthing
COPY supervisord.conf /etc/supervisor/supervisord.conf
......@@ -86,7 +81,7 @@ COPY git* /etc/
RUN ipython profile create --parallel --profile python3 --ipython-dir /opt/conda/etc/ipython
RUN ipython profile create --parallel --profile dev --ipython-dir /opt/conda/etc/ipython
COPY ipcluster_config_python3.py /opt/conda/etc/ipython/profile_python3/ipcluster_config.py
COPY ipcluster_config_python3.py /opt/conda/etc/ipython/profile_dev/ipcluster_config.py
COPY ipcluster_config_dev.py /opt/conda/etc/ipython/profile_dev/ipcluster_config.py
# setting openblas and mkl variables
ENV OPENBLAS_NUM_THREADS=1\
......@@ -95,5 +90,7 @@ ENV OPENBLAS_NUM_THREADS=1\
MKL_NUM_THREADS=1\
CONDA_ALWAYS_COPY=true
# copy startup.sh script and set start-up command
COPY startup.sh /srv/singleuser/
CMD ["sh", "/srv/singleuser/startup.sh"]
EXPOSE 22
c.LocalControllerLauncher.controller_cmd = ['/opt/conda/envs/dev/bin/python', '-m', 'ipyparallel.controller']
c.LocalEngineLauncher.engine_cmd = ['/opt/conda/envs/dev/bin/python', '-m', 'ipyparallel.engine']
c.LocalEngineSetLauncher.engine_cmd = ['/opt/conda/envs/dev/bin/python', '-m', 'ipyparallel.engine']
c.LocalControllerLauncher.controller_cmd = ['/opt/conda/bin/python', '-m', 'ipyparallel.controller']
c.LocalEngineLauncher.engine_cmd = ['/opt/conda/bin/python', '-m', 'ipyparallel.engine']
c.LocalEngineSetLauncher.engine_cmd = ['/opt/conda/bin/python', '-m', 'ipyparallel.engine']
from nb_conda_kernels import CondaKernelSpecManager
from jupyter_client.kernelspec import NATIVE_KERNEL_NAME, KernelSpec
class QTKernelSpecManager(CondaKernelSpecManager):
def find_kernel_specs(self):
kspecs = super(QTKernelSpecManager, self).find_kernel_specs()
# remove the "conda-root" kernelspec
kspecs.pop('conda-root-py', None)
return kspecs
def get_kernel_spec(self, kernel_name):
kspec = super(QTKernelSpecManager, self).get_kernel_spec(kernel_name)
if kernel_name == 'python3':
# override Conda kernel manager display name
kspec = kspec.to_dict()
kspec['display_name'] = 'Python 3'
kspec = KernelSpec(**kspec)
return kspec
NBApp = c.NotebookApp
NBApp.iopub_data_rate_limit = 100000000 # Untill notebook 5.1 is out
NBApp.kernel_spec_manager_class = QTKernelSpecManager
NBApp.nbserver_extensions = {
"nb_conda": True,
"nb_anacondacloud": True,
"nbpresent": True,
"jupyterlab": True,
"jupyter_cms": True,
"jupyter_dashboards": True,
"ipyparallel.nbextension": True,
}
## Global bash profile setup
# add conda to default PATH
export PATH="/opt/conda/bin/:$PATH"
#!/bin/bash
## launch daemonized SSHD
/usr/sbin/sshd
## launch daemonized supervisor
/usr/bin/supervisord
## rename the host to something cool
if [[ -z "$NB_HOSTNAME" ]]; then
hostname "$NB_HOSTNAME"
fi
## start the notebook server
exec /usr/local/bin/start-singleuser.sh $*
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment