k8s dashboard kuboard、kubenav、Lens、kubevious、octant
来源:原创
时间:2021-10-30
作者:脚本小站
分类:Linux
kubevious
helm方式:
官方github:
https://github.com/kubevious/helm
helm安装:
kubectl create namespace kubevious helm repo add kubevious https://helm.kubevious.io helm upgrade --atomic -i kubevious kubevious/kubevious --version 0.8.15 -n kubevious
数据存储在mysql中,所以需要创建pv。
apiVersion: v1 kind: PersistentVolume metadata: name: kubevious spec: accessModes: - ReadWriteOnce capacity: storage: 10Gi claimRef: # 这一段是手动将pv绑定到指定的pvc中,防止被其他pvc绑定,也可以不写 apiVersion: v1 kind: PersistentVolumeClaim name: data-kubevious-mysql-0 namespace: kubevious nfs: path: /opt/nfs/dev server: 192.168.0.150 persistentVolumeReclaimPolicy: Retain
卸载:
helm uninstall kubevious -n kubevious
docker方式:在k8s集群外安装
docker run --name kubevious -p 5001:5001 -v ~/.kube/config:/root/.kube/config:ro kubevious/portable
官方github:
https://github.com/kubevious/portable
评价:没找到查看日志的地方,感觉不是很好用。
octant
github地址:
https://github.com/vmware-tanzu/octant
安装:到release页面下载rpm包,然后安装即可
wget https://github.com/vmware-tanzu/octant/releases/download/v0.24.0/octant_0.24.0_Linux-64bit.rpm yum install octant_0.24.0_Linux-64bit.rpm -y nohup octant --kubeconfig=~/.kube/config --listener-addr=0.0.0.0:8000 &
评价:日志显示不流畅,页面反应比较慢。
kuboard
下载:kuboard里面有关于ingress的配置默认是被注释的,取消注释和改个域名即可。
wget https://kuboard.cn/install-script/kuboard.yaml
部署:部署完成之后需要token访问,
kubectl apply -f kuboard.yaml
创建token:
cat > admin-user.yaml <<EOF apiVersion: v1 kind: ServiceAccount metadata: name: admin-user namespace: kubernetes-dashboard --- apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRoleBinding metadata: name: admin-user roleRef: apiGroup: rbac.authorization.k8s.io kind: ClusterRole name: cluster-admin subjects: - kind: ServiceAccount name: admin-user namespace: kubernetes-dashboard EOF
查看token:
kubectl describe secrets -n kubernetes-dashboard admin-user-token-27xjl
评价:中国人写的,感觉挺好用,部署也方便,最实用的一个。
kubenav
github地址:
https://github.com/kubenav/kubenav
安装:
kubectl apply --kustomize github.com/kubenav/deploy/kustomize
创建Ingress文件:
apiVersion: extensions/v1beta1 kind: Ingress metadata: name: kubenav namespace: kubenav annotations: kubernetes.io/ingress.class: "nginx" nginx.ingress.kubernetes.io/configuration-snippet: | proxy_set_header Upgrade "websocket"; proxy_set_header Connection "Upgrade"; spec: rules: - host: kubenav-dev.demo.com http: paths: - backend: serviceName: kubenav servicePort: 14122 # 注意端口不是80
评价:部署简单,这是一个移动端dashboard,在手机上使用还是很不错的。
skooner
github地址:
https://github.com/skooner-k8s/skooner
安装:
wget https://raw.githubusercontent.com/skooner-k8s/skooner/master/kubernetes-skooner.yaml kubectl apply -f kubernetes-skooner.yaml
创建Ingress资源:
kind: Ingress apiVersion: extensions/v1beta1 metadata: name: skooner namespace: kube-system annotations: kubernetes.io/ingress.class: "nginx" nginx.ingress.kubernetes.io/configuration-snippet: | proxy_set_header Upgrade "websocket"; proxy_set_header Connection "Upgrade"; spec: rules: - host: skooner-dev.demo.com http: paths: - path: / backend: serviceName: skooner servicePort: 80
评价:安装简单,但是东西一般般。
kubehelper
官方github及安装文档:
https://github.com/KubeHelper/kubehelper
创建ingress资源:
kind: Ingress apiVersion: extensions/v1beta1 metadata: name: kubehelper namespace: kubehelper annotations: kubernetes.io/ingress.class: "nginx" nginx.ingress.kubernetes.io/configuration-snippet: | proxy_set_header Upgrade "websocket"; proxy_set_header Connection "Upgrade"; spec: rules: - host: kubehelper-dev.tanzhi.com http: paths: - path: / backend: serviceName: kubehelper-svc servicePort: 80
卸载:
helm uninstall kubehelper -n kubehelper
评价:部署简单,只有搜索,可以搜索资源。
Lens
官方地址:
https://k8slens.dev/
官方github:
https://github.com/lensapp/lens
评价:这是个windows客户端工具,挺好用,直接从官网下载exe安装即可。
Infra app
官方地址:
https://infra.app/
评价:是个windows客户端,套的chrome的壳,简单预览和编辑。
Portainer
部署文件:
https://raw.githubusercontent.com/portiner/k8s/master/deploy/manifests/portainer/portainer.yaml
需要的pv:
apiVersion: v1 kind: PersistentVolume metadata: name: portainer spec: capacity: storage: 10Gi accessModes: - ReadWriteOnce hostPath: path: /data type: DirectoryOrCreate
访问方式:
http://IP:30777/ # https 30779
评价:没啥特别的,略。