add remove
This commit is contained in:
@@ -88,20 +88,17 @@ ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
|
||||
echo 'Asia/Shanghai' > /etc/timezone
|
||||
dpkg-reconfigure -f noninteractive tzdata
|
||||
# 安装所需的软件包
|
||||
apt-get install -y python3 python3-pip gcc g++ build-essential nodejs npm gdebi-core curl wget openssh-server vim lrzsz net-tools sudo git texlive-full
|
||||
apt-get install -y python3 python3-pip gcc g++ build-essential nodejs npm gdebi-core curl wget openssh-server vim lrzsz net-tools sudo git
|
||||
# 创建新用户
|
||||
useradd -m -s /bin/bash ${CREATE_USER}
|
||||
echo "${CREATE_USER}:${CREATE_USER_PASSWD}" | chpasswd
|
||||
echo "${CREATE_USER} ALL=(ALL:ALL) NOPASSWD:ALL" >> /etc/sudoers
|
||||
# 安装micromamba
|
||||
echo "1" | bash <(curl -s https://raw.githubusercontent.com/hotwa/MicroMamba_Installer/main/install.sh)
|
||||
# # 安装micromamba
|
||||
# echo "1" | bash <(curl -s https://raw.githubusercontent.com/hotwa/MicroMamba_Installer/main/install.sh)
|
||||
# 安装 Jupyter 和相关软件
|
||||
npm install -g configurable-http-proxy
|
||||
python3 -m pip install jupyterhub jupyterlab notebook radian pycurl jupyter-rsession-proxy ipykernel jupyterlab-language-pack-zh-CN jupyterlab-git jupyterlab-system-monitor jupyter_nbextensions_configurator jupyter_contrib_nbextensions jupyterlab_widgets jupyterlab-drawio jupyterlab-spreadsheet-editor jupyterlab-cell-flash jedi-language-server jupyterlab_code_formatter jupyterlab-spellchecker jupyterlab_vim nbresuse ipydrawio jedi ipympl black isort theme-darcula ipywidgets tensorboard jupyterlab_latex jupyter_bokeh autopep8 xeus-python jupyterlab-lsp python-lsp-server nglview dockerspawner jupyterhub-nativeauthenticator lckr_jupyterlab_variableinspector
|
||||
EOT
|
||||
|
||||
RUN <<EOT
|
||||
#!/bin/bash
|
||||
python3 -m pip install --default-timeout=10000 jupyterhub jupyterlab notebook radian pycurl jupyter-rsession-proxy ipykernel jupyterlab-language-pack-zh-CN jupyterlab-git jupyterlab-system-monitor jupyter_nbextensions_configurator jupyter_contrib_nbextensions jupyterlab_widgets jupyterlab-drawio jupyterlab-spreadsheet-editor jupyterlab-cell-flash jedi-language-server jupyterlab_code_formatter jupyterlab-spellchecker jupyterlab_vim nbresuse ipydrawio jedi ipympl black isort theme-darcula ipywidgets tensorboard jupyterlab_latex jupyter_bokeh autopep8 xeus-python jupyterlab-lsp python-lsp-server nglview dockerspawner jupyterhub-nativeauthenticator lckr_jupyterlab_variableinspector \
|
||||
-i https://pypi.tuna.tsinghua.edu.cn/simple
|
||||
# install rserver
|
||||
apt update
|
||||
apt update -qq
|
||||
@@ -114,10 +111,6 @@ wget "https://download2.rstudio.org/server/$(lsb_release -cs)/amd64/rstudio-serv
|
||||
chmod +x /tmp/rstudio-server.deb
|
||||
gdebi -n /tmp/rstudio-server.deb
|
||||
rm -rf /tmp/rstudio-server.deb
|
||||
EOT
|
||||
|
||||
RUN <<EOT
|
||||
#!/bin/bash
|
||||
chown -R ${CREATE_USER}:users /home/${CREATE_USER}
|
||||
# 清理和减小镜像大小
|
||||
apt-get clean
|
||||
@@ -126,9 +119,24 @@ EOT
|
||||
|
||||
# Switch back to jovyan to avoid accidental container runs as root
|
||||
USER ${NB_UID}
|
||||
ENV MAMBA_ROOT_PREFIX=/home/${CREATE_USER}/micromamba
|
||||
ENV MAMBA_ROOT_PREFIX=/home/${CREATE_USER}/mamba
|
||||
|
||||
# add pdb env
|
||||
RUN <<EOT
|
||||
#!/bin/bash
|
||||
mamba create -n pdbfixer_env -c conda-forge pdbfixer openmm pymol-open-source rdkit openbabel ipykernel -y
|
||||
mamba run -n pdbfixer_env python -m ipykernel install --user --name="pdbfixer" --display-name="PDBfixer Environment"
|
||||
mamba create -n scardock_env -c conda-forge -c bioconda -c pylyzeng vinautil ipykernel -y
|
||||
mamba run -n scardock_env python -m ipykernel install --user --name="scardock" --display-name="SCARdock Environment"
|
||||
mamba create -n fpocket_env -c conda-forge fpocket ipykernel -y
|
||||
mamba run -n fpocket_env python -m ipykernel install --user --name="fpocket" --display-name="fpocket Environment"
|
||||
EOT
|
||||
|
||||
# SCIplot env
|
||||
RUN <<EOT
|
||||
#!/bin/bash
|
||||
sudo apt update
|
||||
sudo apt install -y texlive-full
|
||||
micromamba create -n plot -c conda-forge scienceplots autopep8 python=3 ipykernel pandas numpy matplotlib scipy seaborn orange3 -y
|
||||
micromamba run -n plot python -m pip install bamboolib
|
||||
micromamba run -n plot python -m ipykernel install --user --name="sciplot" --display-name="SCIPlot Environment"
|
||||
|
||||
Reference in New Issue
Block a user