zoukankan      html  css  js  c++  java
  • kubernetes之5---kubesphere管理平台

    kubesphere管理平台

    kubesphere官网

    Linux上部署官方说明

    准备

    主机 IP 最低要求(每个节点)
    master 10.0.0.21 CPU:2 核,内存:4 G,硬盘:40 G
    node1 10.0.0.22 CPU:2 核,内存:4 G,硬盘:40 G
    node2 10.0.0.23 CPU:2 核,内存:4 G,硬盘:40 G
    • 关闭selinuxfirewalldNetworkManagerpostfix(非必须)

    • 修改IP地址、主机名

    hostnamectl set-hostname 主机名
    sed -i 's/200/IP/g' /etc/sysconfig/network-scripts/ifcfg-eth0
    
    • 所有节点配置时间同步(ntp)
    • 所有节点检查:sshd/sudo/curl/openssl可用
    • 所有节点安装docker并配置镜像加速,会快点。

    下载

    使用 KubeKey v1.0.1 工具安装

    kubekey

    wget https://github.com/kubesphere/kubekey/releases/download/v1.0.1/kubekey-v1.0.1-linux-amd64.tar.gz
    tar xf kubekey-v1.0.1-linux-amd64.tar.gz
    

    创建

    1. 创建配置文件
    ./kk create config --with-kubernetes v1.18.6 --with-kubesphere v3.0.0
    
    1. 修改示例配置文件
    vim config-sample.yaml
    
    # 实际主机名,各节点SSH连接IP,实际IP,SSH登录使用的用户和密码
      hosts:
        - {name: node1, address: 10.0.0.22, internalAddress: 10.0.0.22, user: root, password: 1
    }
    # SSH密钥登陆
        - {name: master, address: 10.0.0.21, internalAddress: 10.0.0.21, privateKeyPath: "~/.ssh/id_rsa"}
    # 实际主机名
      roleGroups:
        etcd:
        - node1
        master:
        - node1
        worker:
        - node1
        - node2
    
    1. 使用配置文件创建集群
    ./kk create cluster -f config-sample.yaml
    yes
    

    整个安装过程可能需要 10 到 20 分钟,具体取决于您的计算机和网络环境。

    添加nodes节点,修改配置文件,执行./kk add nodes -f config-sample.yaml

    完成

    1. 完成后stdout
    #####################################################
    ###              Welcome to KubeSphere!           ###
    #####################################################
    
    Console: http://10.0.0.21:30880
    Account: admin
    Password: P@88w0rd
    
    NOTES:
      1. After logging into the console, please check the
         monitoring status of service components in
         the "Cluster Management". If any service is not
         ready, please wait patiently until all components
         are ready.
      2. Please modify the default password after login.
    
    #####################################################
    https://kubesphere.io             20xx-xx-xx xx:xx:xx
    #####################################################
    
    1. 浏览器访问KubeSphere Web 控制台
    2. 启用kubectl 自动补全
    # Install bash-completion
    apt-get install bash-completion
    
    # Source the completion script in your ~/.bashrc file
    echo 'source <(kubectl completion bash)' >>~/.bashrc
    
    # Add the completion script to the /etc/bash_completion.d directory
    kubectl completion bash >/etc/bash_completion.d/kubectl
    
  • 相关阅读:
    【简单易懂】JPA概念解析:CascadeType(各种级联操作)详解
    [转] @JoinColumn 详解 (javax.persistence.JoinColumn)
    Feign二: @FeignClient 接口调用
    @Basic表示一个简单的属性 懒加载,急加载
    RPC接口测试(一)什么是 RPC 框架
    Mysql中 查询慢的 Sql语句的记录查找
    Mysql 查看连接数,状态 最大并发数
    ntp时间一致对与设备心跳的影响
    jmeter常用四种断言
    jmeter BeanShell断言(四)
  • 原文地址:https://www.cnblogs.com/backups/p/k8s_5.html
Copyright © 2011-2022 走看看