modify_kubeflow_manifest

所属分类:Docker
开发工具:Shell
文件大小:48254KB
下载次数:0
上传日期:2023-06-16 02:34:05
上 传 者sh-1993
说明:  这是Kubeflow Manifest([https: github.com kubeflow manifests)经过修改,可以在国内安装的笔记。非常感谢public- image- mirror(https: github.com ...](https: github.com kubeflow manifests%EF%BC%89%E7%BB%8F%E8%BF%87%E4%BF%AE%E6%94%B9%EF%BC%8C%E5%8F%AF%E4%BB%A5%E5%9C%A8%E5%9B%BD%E5%86%85%E5%AE%89%E8%A3%85%E7%9A%84%E7%AC%94%E8%AE%B0%E3%80%82%E9%9D%9E%E5%B8%B8%E6%84%9F%E8%B0%A2public- image-mirror%EF%BC%88https: github.com DaoCloud public-image- mirror%EF%BC%89%E6%8F%90%E4%BE%9B%E7%9A%84%E9%95%9C%E5%83%8F%E5%8A%A0%E9%80%9F%E
(This is a modified note of Kubeflow Manifest ([https: github. com kubeflow Manifests) that can be installed in China. Thank you very much for public image mirror (https: github. com...] (https: github.com kubeflow manifests% EF% BC% 89% E7% BB% 8F% E8% BF% 87% E4% BF% AE% E6% 94% B9% EF% BC% 8C% E5% 8F% AF% E4% BB% A5% E5% 9C% A8% E5% 9B% BD% E5% 86% 85% E5% AE% 89% E8% A3% 85% E7% 9A% 84% E7% AC% 94% E8% AE% B0% E3% 80% 82% E9% 9D% 9E% E5% B8% B8% E6% 84% 9F% E8% B0% A2public image mirror% EF% BC% 88https: github.com DaoCloud public image mirror% EF% BC% 89% E6% 8F% 90% E4% BE% 9B% E7% 9A% 84% E9% 95% 9C% E5% 83% 8F% E5% 8A% A0% E9% 80% 9F% E)

文件列表:
data-pv-hostpath.yaml (435, 2023-05-10)
data-pvc.yaml (392, 2023-05-10)
erim.py (2230, 2023-05-10)
errimages.txt (2721, 2023-05-10)
example (0, 2023-05-10)
example\kustomization.yaml (8293, 2023-05-10)
kind-ingress-config.yaml (493, 2023-05-10)
manifests.tar.gz (47803350, 2023-05-10)
ori_kustomization.yaml (2334, 2023-05-10)
pull_and_kind_load_dockerimage.sh (4520, 2023-05-10)
pullimages.txt (2241, 2023-05-10)
屏幕截图 2023-05-09 174108.png (1424779, 2023-05-10)
屏幕截图 2023-05-09 174217.png (141764, 2023-05-10)
屏幕截图 2023-05-10 090424.png (49428, 2023-05-10)
屏幕截图 2023-05-10 090443.png (13252, 2023-05-10)

# modify_kubeflow_manifest ### 写在前面 > **这是Kubeflow Manifest "https://github.com/kubeflow/manifests" ,经过少量修改(只改了一个文件,添加了几个文件),可以在国内安装的笔记。**
> **非常感谢public-image-mirror "https://github.com/DaoCloud/public-image-mirror" 提供的镜像加速,使得很多在国外的镜像,在国内也可以下载,只需要改变仓库名(添加'.m.daocloud')。**
> **这里也包括我安装时踩坑记录**
> **这是国内单机本地安装** ### 环境 > **Windows11专业版**
> **WSL2**
> **Ubuntu-22.04**
> **WSL 版本: 1.1.6.0**
> **内核版本: 5.15.90.1**
> **WSLg 版本: 1.0.50**
> **MSRDC 版本: 1.2.3770**
> **Direct3D 版本: 1.608.2-610***218**
> **DXCore 版本: 10.0.25131.1002-220531-1700.rs-onecore-base2-hyp**
> **Windows 版本: 10.0.23451.1000**
> **docker-23.0.2(Linux安装,非windows桌面版)**
> **kind-0.18.0**
> **kubectl-1.25**
> **kustomize-5.0.0**
> **python3**
# 版本 ![](https://github.com/032004129xuzhiyong/modify_kubeflow_manifest/blob/main/%E5%B1%8F%E5%B9%95%E6%88%AA%E5%9B%BE%202023-05-10%20090424.png) ![](https://github.com/032004129xuzhiyong/modify_kubeflow_manifest/blob/main/%E5%B1%8F%E5%B9%95%E6%88%AA%E5%9B%BE%202023-05-10%20090443.png) # 前置条件 ### kind > (kind下载地址) https://kind.sigs.k8s.io/docs/user/quick-start/#installation
> kind version
> kind v0.18.0 go1.20.2 linux/amd***
> kind可以创建多个节点的集群或者多个集群(官网文档:https://kind.sigs.k8s.io/ )
### kubectl > 官网要求(最多1.25)https://github.com/DaoCloud/public-image-mirror
> (kubectl下载地址) 下载需要指定版本 https://kubernetes.io/zh-cn/docs/tasks/tools/install-kubectl-linux/

> kubectl version
> Client Version: version.Info{Major:"1", Minor:"25", GitVersion:"v1.25.0", GitCommit:"a866cbe2e5bbaa01cfd5e969aa3e033f3282a8a2", GitTreeState:"clean", BuildDate:"2022-08-23T17:44:59Z", GoVersion:"go1.19", Compiler:"gc", Platform:"linux/amd***"}

> Kustomize Version: v4.5.7

> Server Version: version.Info{Major:"1", Minor:"26", GitVersion:"v1.26.3", GitCommit:"9e***4106593f3f4aa***f8a84b23db5fa378900bd", GitTreeState:"clean", BuildDate:"2023-03-30T06:34:50Z", GoVersion:"go1.19.7", Compiler:"gc", Platform:"linux/amd***"}
### kustomize > 虽然kubectl中有kustomize,版本不对,要**单独下载**(根据官网要求至少5.0.0) https://github.com/DaoCloud/public-image-mirror
> (kustomize下载地址) https://github.com/kubernetes-sigs/kustomize/releases
> kustomize version
> v5.0.0
### docker > docker version
> Client: Docker Engine - Community
> Version: 23.0.2
> API version: 1.42
> Go version: go1.19.7
> Git commit: 569dd73
> Built: Mon Mar 27 16:16:30 2023
> OS/Arch: linux/amd***
> Context: default

> Server: Docker Engine - Community
> Engine:
> Version: 23.0.2
> API version: 1.42 (minimum version 1.12)
> Go version: go1.19.7
> Git commit: 219f21b
> Built: Mon Mar 27 16:16:30 2023
> OS/Arch: linux/amd***
> Experimental: false
> containerd:
> Version: 1.6.20
> GitCommit: 2806fc1057397dbaeefbea0e4e17bddfbd388f38
> runc:
> Version: 1.1.5
> GitCommit: v1.1.5-0-gf19387a
> docker-init:
> Version: 0.19.0
> GitCommit: de40ad0
### python > python3 # 步骤 ### 第一步 > 只要填写errimages.txt,也就是将不能拉取的gcr.io、quay.io、ghcr.io开头的镜像复制进去
> 原本是笔者不能拉取的镜像列表
### 第二步 > 解压manifests.tar.gz(这是kubeflow manifests的源文件)
> 将这里的除README.md、.git、屏幕截图、压缩包外的文件复制到解压的官网manifests目录下
### 第三歩 > 注意:在运行前,如果对挂载、节点等有要求,先修改kind-ingress-config.yaml(里面笔者挂载了本地的jupyterlab的目录)
> 这步包括:修改宿主机打开文件个数限制--导出镜像列表,更改配置文件(example/*)--建立集群(一个节点)--启动(初始化)kubeflow(无限循环,不会结束,可以手动结束)
> 在解压的官网manifests目录下运行pull_and_kind_load_dockerimage.sh
### 第四步 > 根据下面的Warning进行补充操作
# Warning ### warning1 > 如果没有auth(namespace),重新用这条命令加载,在打开另一个终端输入
> kustomize build common/dex/overlays/istio | kubectl apply -f -
### warning2 > 记得如果kubeflow-user-example-com 或者 auth (两个都是namespace) 中的pod 镜像加载错误,就手动修改(添加".m.daocloud")
> 因为可能后面加载的pod,image还是拉取国外
> kubectl edit pod -n namespace podname
### warning3 > 踩坑踩坑,注意是对ingressgateway服务(svc)进行端口映射,不是对pod.....
> 临时端口映射,登录浏览器(127.0.0.1:8080)输入账号user@example.com 输入密码12341234
> kubectl port-forward -n istio-system svc/istio-ingressgateway 8080:80
### warning4 > 补充
> 从本地(宿主机)将目录挂载到集群中,笔者要用到本地的jupyterlab目录的代码和数据,所以声明到pvc中,使用时引用pvc的name。
> kubectl create -f data-pv-hostpath.yaml (其中持久卷挂载的源目录是/home,和上面kind-ingress-config.yaml中的containerPath: /home要一样)
> kubectl create -f data-pvc.yaml (持久卷声明,使用了上面的持久卷,当要使用的时候就将它的name声明在volumns中)
# 安装成功 ### 所有运行的pod ![运行的pod](https://github.com/032004129xuzhiyong/modify_kubeflow_manifest/blob/main/%E5%B1%8F%E5%B9%95%E6%88%AA%E5%9B%BE%202023-05-09%20174108.png) ### kubeflow界面 **使用`kubectl port-forward -n istio-system svc/istio-ingressgateway 8080:80`进行临时端口映射,访问本地浏览器127.0.0.1:8080,出现界面。** ![界面](https://github.com/032004129xuzhiyong/modify_kubeflow_manifest/blob/main/%E5%B1%8F%E5%B9%95%E6%88%AA%E5%9B%BE%202023-05-09%20174217.png)

近期下载者

相关文件


收藏者