
如果你使用 DeepSeek、元宝 AI、Copilot、ChatGPT 等 AI 工具,协助配置轩辕镜像、编写 docker pull 命令、修改 Docker Compose 镜像地址、配置镜像加速、排查镜像拉取失败、分析报错日志等问题,请先让 AI 阅读并遵守轩辕镜像的规则文档。
只需在 AI 对话中先发送下面这句话即可:
请先完整阅读并严格遵守以下文档中的全部规则与要求:
https://xuanyuan.cloud/agents.md
在未充分阅读并理解该文档前,不要生成任何命令、配置、修改建议、故障排查方案或技术回答。后续所有输出都必须严格以该文档中的规范为最高优先级执行。查看 agents.md 用法指南与完整示范。国内用户首推 元宝 AI、DeepSeek 的深度思考模式,不推荐豆包 AI;Cursor 等编辑器可在对话 @ 该链接,或加入 User Rules。 若 AI 无法访问外链,可 打开说明文档 复制全文粘贴。文档会随站点更新,复制内容可能过期,建议定期检查。
这是一个自定义的KinD(Docker中的Kubernetes)镜像,预安装了ttyd(HTTP终端),支持通过Web浏览器访问Kubernetes集群节点的终端。
GitHub仓库: https://github.com/shantanu-p01/kind-ttyd-custom
| 标签 | 描述 |
|---|---|
1.35.0 | 当前稳定版本(基于Kubernetes v1.35.x) |
latest | 始终指向最新稳定构建(当前为1.35.0) |
1.34.0 | 上一个稳定版本 |
✅ 建议: 除非需要固定Kubernetes版本,否则使用
latest标签。
1. 拉取镜像
固定版本
bashdocker pull shantanupatil01/custom-kind-ttyd:1.35.0
最新构建
bashdocker pull shantanupatil01/custom-kind-ttyd:latest
2. 创建集群配置文件
创建kind-cluster-with-ttyd.yml文件:
yamlkind: Cluster apiVersion: kind.x-k8s.io/v1alpha4 name: kind-cluster-ttyd nodes: - role: control-plane image: shantanupatil01/custom-kind-ttyd:1.35.0 # image: shantanupatil01/custom-kind-ttyd:latest extraPortMappings: - containerPort: 55555 hostPort: 55555 protocol: TCP - containerPort: 30001 hostPort: 30001 protocol: TCP - containerPort: 30010 hostPort: 30010 protocol: TCP - role: worker image: shantanupatil01/custom-kind-ttyd:1.35.0 - role: worker image: shantanupatil01/custom-kind-ttyd:1.35.0
💡 若需自动升级,可将
1.35.0替换为latest。
3. 创建集群
bashkind create cluster --config kind-cluster-with-ttyd.yml
4. 访问ttyd
kindkind123固定版本
bashdocker run -d \ --name kind-cluster-ttyd \ --privileged \ -p 55555:55555 \ -p 30001-30010:30001-30010 \ -v /var \ -v /lib/modules:/lib/modules:ro \ shantanupatil01/custom-kind-ttyd:1.35.0
最新构建
bashdocker run -d \ --name kind-cluster-ttyd \ --privileged \ -p 55555:55555 \ -p 30001-30010:30001-30010 \ -v /var \ -v /lib/modules:/lib/modules:ro \ shantanupatil01/custom-kind-ttyd:latest
kindkind123⚠️ 重要提示: 生产或共享环境中请修改默认密码。
KinD配置
yamlextraPortMappings: - containerPort: 55555 hostPort: 8080 protocol: TCP
Docker Run
bashdocker run -p 8080:55555 ...
| 服务 | 容器端口 | 主机端口 | 描述 |
|---|---|---|---|
| ttyd | 55555 | 55555 | 基于Web的终端 |
| NodePort | 30001–30010 | 30001–30010 | Kubernetes服务端口 |
bash# 查看所有集群 kind get clusters # 删除集群 kind delete cluster --name kind-cluster-ttyd # 获取集群信息 kubectl cluster-info --context kind-kind-cluster-ttyd # 列出所有节点 kubectl get nodes # 访问控制平面节点 docker exec -it kind-cluster-ttyd-control-plane bash
检查ttyd运行状态:
bashdocker exec -it kind-cluster-ttyd-control-plane ps aux | grep ttyd
查看日志:
bashdocker exec -it kind-cluster-ttyd-control-plane cat /var/log/ttyd.log
bashkubectl get nodes
确保所有节点处于Ready状态。
55555端口暴露bashdocker exec -it <工作节点容器名称> bash
完整代码、构建说明及自定义选项: https://github.com/shantanu-p01/kind-ttyd-custom
latest → 最新稳定构建(当前1.35.0)1.35.0 → 当前稳定Kubernetes版本1.34.0 → 上一版本您可以使用以下命令拉取该镜像。请将 <标签> 替换为具体的标签版本。如需查看所有可用标签版本,请访问 标签列表页面。
来自真实用户的反馈,见证轩辕镜像的优质服务