本帖最后由 afterlop 于 2023-10-06 16:21 编辑
原始用途是方便快捷的在按小时计费的超大型服务器上部署python环境进行科学计算,充分利用时间别浪费在构建环境上。
该项目收录在 https://virt.spiritlhl.net/ 中
说明:
- 本脚本尝试使用Miniconda3安装虚拟环境jupyter-env再进行jupyter和jupyterlab的安装,如若安装机器不纯净勿要轻易使用本脚本!
- 本脚本为实验性脚本可能会有各种bug,勿要轻易尝试!使用前务必保证宿主机系统随时可重装,无重要数据在服务器上!
- 验证已支持的系统:
- Ubuntu 系 - 推荐,脚本自动挂起到后台
- Debian 系 - 部分可能需要手动挂起到后台,详看脚本运行安装完毕的后续提示
- 可能支持的系统(未验证):centos 7+,Fedora,Almalinux 8.5+
- 执行脚本,之前有用本脚本安装过则直接打印设置的登陆信息,没安装过则进行安装再打印信息,如果已安装但未启动则自动启动后再打印信息
- 如果是初次安装无脑输入y回车即可,按照提示进行操作即可,安装完毕将在后台常驻运行,自动添加常用的安装包通道源
- 安装完毕后,如果需要在lab中安装第三方库需要在lab中使用terminal并使用conda进行下载而不是pip3下载,这是需要注意的一点
- 安装过程中有判断是否为中国IP,可选择是否使用中国镜像
国际:
curl -L https://raw.githubusercontent.com/spiritLHLS/one-click-installation-script/main/install_scripts/jupyter.sh -o jupyter.sh && chmod +x jupyter.sh && bash jupyter.sh
国内: curl -L https://ghproxy.com/https://raw.githubusercontent.com/spiritLHLS/one-click-installation-script/main/install_scripts/jupyter.sh -o jupyter.sh && chmod +x jupyter.sh && bash jupyter.sh
由于本人经常需要在不同linux服务器上构建python环境进行科学计算,而且时常需要与朋友协作构建项目,一般都使用jupyter lab进行协作,故而在这里分享给大家
同时还配备有一个自动同步备份某个文件夹到github仓库的脚本在这里
https://github.com/spiritLHLS/auto-push
使用说明在仓库说明中,不过多赘述了(设置好后每次执行一下push.sh文件就能自动推送更改上仓库了)
宿主机内存不够用那就用这个开虚拟内存
https://virt.spiritlhl.net/case/case5.html
(我知道有人喜欢linux上用code-server,但我实在是不习惯每次print都要从头跑还得打print,所以诞生了这些项目)
项目运行截图如下 






|