专注于分布式系统架构AI辅助开发工具(Claude
Code中文周刊)

Kubernetes Essentials - Build Docker Desktop K8S With Aliyun - Lesson 02

智谱 GLM,支持多语言、多任务推理。从写作到代码生成,从搜索到知识问答,AI 生产力的中国解法。

![]([object Object])
This article provides a step-by-step guide on setting up a Kubernetes (K8s) dashboard on Docker Desktop for Mac. It
covers the entire process from building the Docker Desktop K8s environment to creating a dashboard, generating access
tokens, and logging in.

Download DockerDeskTop

The procedures utilize Alibaba Cloud's Kubernetes GitHub project, offering practical insights for developers working
with containerized applications in a Mac environment."

https://www.docker.com/products/docker-desktop/

Use ALiYun K8s for deskTop

git clone https://github.com/AliyunContainerService/k8s-for-docker-desktop.git
cd k8s-for-docker-desktop

./load_images.sh

Change user Context

kubectl config use-context docker-desktop

GetClusterInfo

kubectl cluster-info
kubectl get nodes

CreateDashboard

kubectl create -f kubernetes-dashboard.yaml
kubectl get pod -n kubernetes-dashboard
kubectl proxy

BuildToken

kubectl apply -f kube-system-default.yaml
TOKEN=$(kubectl -n kube-system describe secret default| awk '$1=="token:"{print $2}')
kubectl config set-credentials docker-desktop --token="${TOKEN}"
echo $TOKEN

Dashboard Login

http://localhost:8001/api/v1/namespaces/kubernetes-dashboard/services/https:kubernetes-dashboard:/proxy/#/login

Quote

  1. Mac + Docker + K8S 本地搭建K8S集群
赞(0)
未经允许不得转载:Toy Tech Blog » Kubernetes Essentials - Build Docker Desktop K8S With Aliyun - Lesson 02
免费、开放、可编程的智能路由方案,让你的服务随时随地在线。

评论 抢沙发

十年稳如初 — LocVPS,用时间证明实力

10+ 年老牌云主机服务商,全球机房覆盖,性能稳定、价格厚道。

老品牌,更懂稳定的价值你的第一台云服务器,从 LocVPS 开始