05 2022 档案
摘要:一丶安装ansible 1.yum安装ansible yum install epel-release -y yum install ansible -y ansible --version 2.Ansible的命令参数 ansible命令语法: ansible [-i 主机文件] [-f 批次]
阅读全文
摘要:centos7安装docker-compose 1丶下载docker compose指定的版本: sudo curl -L "https://github.com/docker/compose/releases/download/1.24.1/docker-compose-$(uname -s)-$
阅读全文
摘要:yum install -y bash-completion source /usr/share/bash-completion/bash_completion source <(kubectl completion bash) echo "source <(kubectl completion b
阅读全文
摘要:ETCDCTL_API=3 /opt/kube/bin/etcdctl --endpoints=https://zy-jp-pg-pro-k8s-master01:2379,https://zy-jp-pg-pro-k8s-master02:2379,https://zy-jp-pg-pro-k8s
阅读全文
摘要:#!/bin/bash #API usage reference https://github.com/goharbor/harbor/blob/v1.7.5/docs/swagger.yaml Harbor_URL=http://172.31.170.19/ #SSL证书 #cacert="/da
阅读全文
摘要:需求: 当node节点宕机时,希望该node节点上的pod能够快速疏散到其他节点,并提供服务。默认要等待5分钟,上面的pod才会疏散。 方式一丶 通过配置控制器 cat web.yaml apiVersion: apps/v1 kind: Deployment metadata: labels: a
阅读全文
摘要:在execute shell输入框中加入BUILD_ID=DONTKILLME,即可防止jenkins杀死如:项目的启动脚本,git clone批量脚本。。。等 //阶段2 获取代码 stage("获取代码"){ steps{ script{ PrintMes("获取代码","green") sh
阅读全文
摘要:一丶下载安装包 下载地址:https://github.com/kubernetes/kubernetes/tree/master/CHANGELOG wget https://dl.k8s.io/v1.20.11/kubernetes-server-linux-amd64.tar.gz 解压并做软
阅读全文
摘要:1、安装证书签发工具 下载地址:https://github.com/cloudflare/cfssl/releases wget -O /usr/bin/cfssl https://github.com/cloudflare/cfssl/releases/download/v1.6.1/cfssl
阅读全文
摘要:1.修改主机名(分别操作)hostnamectl set-hostname k8s-master01 && bashhostnamectl set-hostname k8s-master02 && bashhostnamectl set-hostname k8s-master03 && bashho
阅读全文