zoukankan      html  css  js  c++  java
  • 安装Minikube无法访问k8s.gcr.io的简单解决办法

    学习Kubenetes,安装Minikube报错。提示无法访问k8s.gcr.io。

    上网搜索,好像多数方法是用Docker拉取镜像改标签。感觉比较麻烦。

    想用本地镜像库,运行:

    minikube start --help |grep repo

          --image-repository='': Alternative image repository to pull docker images from. This can be used when you have limited access to gcr.io. Set it to "auto" to let minikube decide one for you. For Chinese mainland users, you may use local gcr.io mirrors such as registry.cn-hangzhou.aliyuncs.com/google_containers

    看到官方建议的解决方法是使用阿里云服务器。

    使用下面的命令就可以安装:

    sudo minikube start --image-repository='registry.cn-hangzhou.aliyuncs.com/google_containers'

     补充:

    发现还有一个参数,应该设置为cn。好像加了没变化,连不上的还是连不上。

    --image-mirror-country='': Country code of the image mirror to be used. Leave empty to use the global one. For Chinese mainland users, set it to cn.

  • 相关阅读:
    500 多个 Linux 命令文档搜索
    C++ 字符串基本操作
    串的模式匹配算法
    查看、启动、关闭防火墙
    天润融通面试
    LeetCode 169. 求众数
    【面试题】人人车一次面试总结
    一个完整的 JS 身份证校验代码
    oracle多表查询
    百度地图的Icon
  • 原文地址:https://www.cnblogs.com/pack27/p/12202687.html
Copyright © 2011-2022 走看看