背景

JupyterHub 为用户组带来了笔记本的强大功能。它使用户能够访问计算环境和资源,而不会给用户带来安装和维护任务的负担。用户——包括学生、研究人员和数据科学家——可以在他们自己的工作空间中完成他们的工作,共享资源可以由系统管理员有效管理。

JupyterHub 在云端或您自己的硬件上运行,可以为世界上的任何用户提供预先配置的数据科学环境。它是可定制和可扩展的,适用于小型和大型团队、学术课程和大型基础设施。

第一步、参考:https://cloud.tencent.com/developer/article/1902519 创建动态挂载存储

第二步、安装helm

root@hello:~# curl https://baltocdn.com/helm/signing.asc | sudo apt-key add -
root@hello:~# sudo apt-get install apt-transport-https --yes
root@hello:~# echo "deb https://baltocdn.com/helm/stable/debian/ all main" | sudo tee /etc/apt/sources.list.d/helm-stable-debian.list
root@hello:~# sudo apt-get update
root@hello:~# sudo apt-get install helm

第三步、导入镜像

root@hello:~# docker load -i pause-3.5.tar
root@hello:~# docker load -i kube-scheduler.tar

第四步、安装jupyterhub

helm repo add jupyterhub https://jupyterhub.github.io/helm-chart/

helm repo update

helm upgrade --cleanup-on-fail \
--install ju jupyterhub/jupyterhub \
--namespace ju \
--create-namespace \
--version=1.2.0 \
--values config.yaml

注:此文件可以自定义内容,具体看注释,如下开启lab功能

root@hello:~# vim config.yaml
root@hello:~# cat config.yaml
# This file can update the JupyterHub Helm chart's default configuration values.
# #
# # For reference see the configuration reference and default values, but make
# # sure to refer to the Helm chart version of interest to you!
# #
# # Introduction to YAML: https://www.youtube.com/watch?v=cdLNKUoMc6c
# # Chart config reference: https://zero-to-jupyterhub.readthedocs.io/en/stable/resources/reference.html
# # Chart default values: https://github.com/jupyterhub/zero-to-jupyterhub-k8s/blob/HEAD/jupyterhub/values.yaml
# # Available chart versions: https://jupyterhub.github.io/helm-chart/
# #
singleuser:
defaultUrl: "/lab"
extraEnv:
JUPYTERHUB_SINGLEUSER_APP: "jupyter_server.serverapp.ServerApp" #singleuser:
# defaultUrl: "/lab"
# extraEnv:
# JUPYTERHUB_SINGLEUSER_APP: "notebook.notebookapp.NotebookApp"
root@hello:~# 
root@hello:~#
root@hello:~#

第五步、修改svc为nodeport

root@hello:~# kubectl get svc  -A
NAMESPACE NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
default kubernetes ClusterIP 10.68.0.1 <none> 443/TCP 16h
ju hub ClusterIP 10.68.60.16 <none> 8081/TCP 114s
ju proxy-api ClusterIP 10.68.239.54 <none> 8001/TCP 114s
ju proxy-public LoadBalancer 10.68.62.47 <pending> 80:32070/TCP 114s
kube-system dashboard-metrics-scraper ClusterIP 10.68.244.241 <none> 8000/TCP 16h
kube-system kube-dns ClusterIP 10.68.0.2 <none> 53/UDP,53/TCP,9153/TCP 16h
kube-system kube-dns-upstream ClusterIP 10.68.221.104 <none> 53/UDP,53/TCP 16h
kube-system kubernetes-dashboard NodePort 10.68.206.196 <none> 443:32143/TCP 16h
kube-system metrics-server ClusterIP 10.68.1.149 <none> 443/TCP 16h
kube-system node-local-dns ClusterIP None <none> 9253/TCP 16h
root@hello:~# kubectl edit svc proxy-public -n ju
service/proxy-public edited
root@hello:~#
root@hello:~#
root@hello:~# kubectl get svc -A
NAMESPACE NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
default kubernetes ClusterIP 10.68.0.1 <none> 443/TCP 16h
ju hub ClusterIP 10.68.60.16 <none> 8081/TCP 2m19s
ju proxy-api ClusterIP 10.68.239.54 <none> 8001/TCP 2m19s
ju proxy-public NodePort 10.68.62.47 <none> 80:32070/TCP 2m19s
kube-system dashboard-metrics-scraper ClusterIP 10.68.244.241 <none> 8000/TCP 16h
kube-system kube-dns ClusterIP 10.68.0.2 <none> 53/UDP,53/TCP,9153/TCP 16h
kube-system kube-dns-upstream ClusterIP 10.68.221.104 <none> 53/UDP,53/TCP 16h
kube-system kubernetes-dashboard NodePort 10.68.206.196 <none> 443:32143/TCP 16h
kube-system metrics-server ClusterIP 10.68.1.149 <none> 443/TCP 16h
kube-system node-local-dns ClusterIP None <none> 9253/TCP 16h
root@hello:~#

https://blog.csdn.net/qq_33921750

https://my.oschina.net/u/3981543

https://www.zhihu.com/people/chen-bu-yun-2

https://segmentfault.com/u/hppyvyv6/articles

https://juejin.cn/user/3315782802482007

https://space.bilibili.com/352476552/article

https://cloud.tencent.com/developer/column/93230

知乎、CSDN、开源中国、思否、掘金、哔哩哔哩、腾讯云

Kubernetes(k8s)集群安装JupyterHub以及Lab的更多相关文章

  1. Kubernetes(k8s)集群安装

    一:简介 二:基础环境安装 1.系统环境 os Role ip Memory Centos 7 master01 192.168.25.30 4G Centos 7 node01 192.168.25 ...

  2. kubernetes(k8s)集群安装calico

    添加hosts解析 cat /etc/hosts 10.39.7.51 k8s-master-51 10.39.7.57 k8s-master-57 10.39.7.52 k8s-master-52 ...

  3. K8s集群安装--最新版 Kubernetes 1.14.1

    K8s集群安装--最新版 Kubernetes 1.14.1 前言 网上有很多关于k8s安装的文章,但是我参照一些文章安装时碰到了不少坑.今天终于安装好了,故将一些关键点写下来与大家共享. 我安装是基 ...

  4. [转帖]K8s集群安装--最新版 Kubernetes 1.14.1

    K8s集群安装--最新版 Kubernetes 1.14.1 http://www.cnblogs.com/jieky/p/10679998.html 原作者写的比较简单 大略流程和跳转的多一些 改天 ...

  5. Centos7 安装部署Kubernetes(k8s)集群

    目录 一.系统环境 二.前言 三.Kubernetes 3.1 概述 3.2 Kubernetes 组件 3.2.1 控制平面组件 3.2.2 Node组件 四.安装部署Kubernetes集群 4. ...

  6. Istio(二):在Kubernetes(k8s)集群上安装部署istio1.14

    目录 一.模块概览 二.系统环境 三.安装istio 3.1 使用 Istioctl 安装 3.2 使用 Istio Operator 安装 3.3 生产部署情况如何? 3.4 平台安装指南 四.Ge ...

  7. Kubernetes(k8s)集群部署(k8s企业级Docker容器集群管理)系列之自签TLS证书及Etcd集群部署(二)

    0.前言 整体架构目录:ASP.NET Core分布式项目实战-目录 k8s架构目录:Kubernetes(k8s)集群部署(k8s企业级Docker容器集群管理)系列目录 一.服务器设置 1.把每一 ...

  8. K8S集群安装部署

    K8S集群安装部署   参考地址:https://www.cnblogs.com/xkops/p/6169034.html 1. 确保系统已经安装epel-release源 # yum -y inst ...

  9. 使用kubectl管理Kubernetes(k8s)集群:常用命令,查看负载,命名空间namespace管理

    目录 一.系统环境 二.前言 三.kubectl 3.1 kubectl语法 3.2 kubectl格式化输出 四.kubectl常用命令 五.查看kubernetes集群node节点和pod负载 5 ...

  10. Kubernetes(k8s)集群部署(k8s企业级Docker容器集群管理)系列目录

    0.目录 整体架构目录:ASP.NET Core分布式项目实战-目录 k8s架构目录:Kubernetes(k8s)集群部署(k8s企业级Docker容器集群管理)系列目录 一.感谢 在此感谢.net ...

随机推荐

  1. Coder vs Programmer: Difference You Should Know

    In this tech-driven world, you may have heard the terms 'coder' and 'programmer' used interchangeabl ...

  2. swoft-个基于 Swoole 原生协程的PHP 微服务框架

    刚才百度了一下swoft框架,官网打不开了,仓库也暂停了.不由感慨.曾经和同事踩了许多坑使用此极其小众的框架完成微服务项目.使用它的唯一目的就是提高程序性能(底层使用了协程),为此大家都学习了很多新知 ...

  3. net-snmp 自定义OID利用脚本获取值

    两种办法: 1)pass方式 /etc/snmp/snmpd.conf 写脚本 脚本需要注意:要连续输出三行:1.OID 2.类型 3.值 如果不按照这个规定,直接输出值,将会报错. 检查 第二种方法 ...

  4. linux-minicom

    q:只能发送不能接收 a:串口设置,硬件流控制=>NO

  5. Java定时器Timer和TimerTask

    方式一:设定指定任务task在指定时间time执行 schedule(TimerTask task, Date date)   public static void main(String[] arg ...

  6. 关于QT编译程序找不到MSVCRT.DLL和其他动态链接库的解决办法

    先上图(一大堆无法解析的外部符号): 解决办法分两个步骤: 1.系统环境变量设置,把这些dll文件所在目录加入到PATH中.比如C:\Windows\SysWOW64, C:\Windows\Syst ...

  7. Net6 读取POST请求 BODY中的内容

    StreamReader stream = new StreamReader(Request.Body); string body = stream.ReadToEndAsync().GetAwait ...

  8. K8S Operator的开发与使用

    从应用角度考虑,为什么会出现如此多的Operator场景,为什么很多中间件和厂商都会提供基于Operator的部署方案,他的价值是什么? 随着时代的发展,企业应用部署环境从传统的物理机->虚拟机 ...

  9. NX1946_MoldWizard 注塑模向导建立标准库

    NX1946_MoldWizard 注塑模向导建立标准库

  10. 日常笔记-VS

    VS快捷键 按键 作用 CTRL+R,CTRL+W 以点显示空格 CTRL+L 删除当前行 CTRL+D 重复当前行 CTRL+K,D 格式化代码 CTRL+M 展开代码