zoukankan      html  css  js  c++  java
  • 自学k8s-安装过程为下载flannel.yml和镜像文件,而需要设置的代理

    1、yum代理设置
    编辑文件为:/etc/yum.conf
    在里面添加这一行:proxy=IP:PORT
    这里的IP 为你要设置的IP ,PORT 是你要设置的端口

    2、wget的代理设置

    用vi/vim编辑器打开/etc/wgetrc,找到代理设置所在行,然后追加如下内容:
    # You can set the default proxies for Wget to use for http, https, and ftp.
    # They will override the value in the environment.
    #https_proxy = http://proxy.yoyodyne.com:18023/
    #http_proxy = http://proxy.yoyodyne.com:18023/
    #ftp_proxy = http://proxy.yoyodyne.com:18023/
    添加下面两行:
    http_proxy = IP:PORT
    ftp_proxy = IP:PORT

    [root@k8s-master ~]# vim /etc/wgetrc 
    [root@k8s-master ~]# wget https://raw.githubusercontent.com/coreos/flannel/master/Documentation/kube-flannel.yml
    --2020-11-14 02:27:37--  https://raw.githubusercontent.com/coreos/flannel/master/Documentation/kube-flannel.yml
    Connecting to 139.224.67.47:8789... connected.
    Proxy request sent, awaiting response... 200 OK
    Length: 4813 (4.7K) [text/plain]
    Saving to: ‘kube-flannel.yml’
    
    100%[==============================================================================================>] 4,813       --.-K/s   in 0s      
    
    2020-11-14 02:27:37 (37.7 MB/s) - ‘kube-flannel.yml’ saved [4813/4813]
    
    [root@k8s-master ~]# ls
    anaconda-ks.cfg  kube-flannel.yml  original-ks.cfg
    [root@k8s-master ~]# vim /etc/yum.conf 
    [root@k8s-master ~]# 

     

  • 相关阅读:
    Go语言并发编程
    Go语言package
    大数据实践(十) Spark多种开发语言、与Hive集成
    大数据实践(九)--sqoop安装及基本操作
    Go语言错误处理
    Go语言接口
    Go语言面向对象
    数据库基础了解
    PL/SQL语句快捷输入设置
    重载操作符介绍
  • 原文地址:https://www.cnblogs.com/potato-chip/p/13974268.html
Copyright © 2011-2022 走看看