diff --git a/setup_apps_conda.sh b/setup_apps_conda.sh index 9beb650..219a320 100644 --- a/setup_apps_conda.sh +++ b/setup_apps_conda.sh @@ -47,7 +47,7 @@ echo "create virtualenv and install JupyterHub..." python3 -m venv /opt/jupyterhub/ /opt/jupyterhub/bin/python3 -m pip install wheel /opt/jupyterhub/bin/python3 -m pip install jupyterhub jupyterlab -/opt/jupyterhub/bin/python3 -m pip install ipywidgets +/opt/jupyterhub/bin/python3 -m pip install ipywidgets jupyterlab-git jupyter-server-proxy npm install -g configurable-http-proxy echo "setup jupyterhub config..." @@ -84,15 +84,22 @@ apt-get install -y conda #symlinking the conda shell setup script to the profile ‘drop in’ folder so that it gets run on login: ln -s /opt/conda/etc/profile.d/conda.sh /etc/profile.d/conda.sh -mkdir /opt/conda/envs/ +mkdir -p /opt/conda/envs/ /opt/conda/bin/conda create --prefix /opt/conda/envs/python python=3.7 ipykernel -#/opt/conda/envs/python/bin/python -m ipykernel install --prefix /usr/local/ --name 'python' --display-name "Python (default)" -/opt/conda/envs/python/bin/python -m ipykernel install --prefix=/opt/jupyterhub/ --name 'python' --display-name "Python (default)" +/opt/conda/envs/python/bin/python -m ipykernel install --prefix /usr/local/ --name 'python' --display-name "Python (default)" +#/opt/conda/envs/python/bin/python -m ipykernel install --prefix=/opt/jupyterhub/ --name 'python' --display-name "Python (default)" + +#install ofen used python packages for default environment +/opt/conda/bin/conda install h5py tqdm pandas pillow matplotlib ipympl opencv-python --yes --name python +/opt/conda/bin/conda install cantera --channel cantera --yes --name python + #users have to setup there kernel like this: -#/opt/conda/envs/python/bin/python -m ipykernel install --name 'python-my-env' --display-name "Python My Env" +#create conder enviroment: +#conda create ipykernel --name mypersonal_enviroment +#python -m ipykernel install --user --name mypersonal_enviroment --display-name "Python My Env" #conda install --yes jupyterhub jupyterlab notebook configurable-http-proxy jupyterlab-git jupyter-server-proxy @@ -117,8 +124,8 @@ mkdir /opt/conda/envs/ #on http://0.0.0.0:19999 #echo "Install gpuview..." -#python3 -m pip install gpuview -#gpuview service --host 127.0.0.1 --port 9988 +#/opt/jupyterhub/bin/python3 -m pip install gpuview +#/opt/jupyterhub/bin/python3 -m gpuview service --host 127.0.0.1 --port 9988 <-- fails #echo "Disable services that delays startup by wating for network connectivity..." #systemctl disable cloud-config @@ -128,6 +135,7 @@ mkdir /opt/conda/envs/ echo "Start JupyterHub..." systemctl start jupyterhub.service +#sudo systemctl restart jupyterhub echo "" echo "Setup successfully finished"