Deployment in China
Deployment in China will face some network-related issues. @siaimes has a good solution on this. Please use this issue to discuss this topic.
具体方案参考下面的仓库:
https://github.com/siaimes/k8s-share
原理:
- 提前将资源文件同步到一个镜像里面,并在本地任意一台集群中节点能访问到的机器上启动一个容器,然后将配置文件中的文件地址指向该容器,从而解决资源文件无法下载的问题;(只需一行命令)
- 使用镜像同步服务将gcr的镜像同步到dockerhub,由于dockerhub国内还可以访问,故解决了镜像无法拉取的问题。(无痛)
有些地区nvidia.github.io被DNS污染(DNS返回127.0.0.1),导致安装nvidia-container-runtime失败,解决方法是在/etc/hosts中加入如下记录:
185.199.110.153 nvidia.github.io

我的博客中还有许多与网络无关的可能导致安装失败或运行中出现故障的细节就不贴在这里了,需要的朋友可以自行浏览我的博客:https://blog.siaimes.me/2022/05/30/p62.html
Thanks @siaimes for sharing the solution.
Thanks, your solution is very useful. And I am maintaining a Open Source Mirror and I am willing to mirror these files on my site, could you please give me the whole file list?
Thanks, your solution is very useful. And I am maintaining a Open Source Mirror and I am willing to mirror these files on my site, could you please give me the whole file list?
I have sent an email to you, please check your mailbox, and look forward to your update of the mirror link.
another mirror is online https://mirrors.geekpie.tech/k8s-share/
I figured out a way to use registry.aliyuncs.com to pull required docker images. Just try this config.yaml:
https://gist.github.com/cdpath/19c8cb90d4e109e2e9b5c711d2369ea2