我目前可以这样部署,还是有点繁琐,
1、create_project_harbor.sh没有包含在离线包里
2、要改create_project_harbor.sh,现在registry都是基于registry v2了吧
3、kubesphere-all-v3.0.0-offline-linux-amd64.tar.gz这个包略大一些,不过也大不是很多
基于k8s 离线部署kubesphere
1、准备harbor镜像仓库,镜像仓库地址:http://192.168.93.9
2、下载kubesphere离线镜像包并解压
curl -Ok https://kubesphere-installer.pek3b.qingstor.com/offline/v3.0.0/kubesphere-all-v3.0.0-offline-linux-amd64.tar.gz
tar -zxvf kubesphere-all-v3.0.0-offline-linux-amd64.tar.gz
3、推送镜像到harbor仓库
下载脚本
wget https://raw.githubusercontent.com/kubesphere/ks-installer/master/scripts/create_project_harbor.sh
修改create_project_harbor.sh脚本,指定镜像仓库地址和登录信息:
url="http://192.168.93.9"
user="admin"
passwd="Harbor12345"
如果使用2.x版本harbor修改最后行为以下内容:
${url}/api/v2.0/projects
创建项目
sh create_project_harbor.sh
推送镜像到私有镜像仓库
cd kubesphere-all-v3.0.0-offline-linux-amd64/kubesphere-images-v3.0.0
sh push-images.sh 192.168.93.9
3、部署kubesphere容器平台
helm repo add test https://charts.kubesphere.io/test
helm pull test/ks-installer
tar -zxvf ks-installer-0.2.1.tgz
helm install kubesphere \
--namespace=kubesphere-system \
--create-namespace \
--set image.repository=192.168.93.9/kubesphere/ks-installer \
--set image.tag=v3.0.0 \
--set persistence.storageClass=longhorn \
--set .registry=192.168.93.9 \
./ks-installer