k8s storageclass 创建权限相关资源rbac.yaml 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263apiVersion: v1kind: ServiceAccountmetadata: name: nfs-client-pro 2021-11-24 k8s #运维 #k8s
k8s 配置自签发ssl证书 有的pod需要访问api-server时使用的https协议 删除之前的默认生成的secret12345# 查看default命名空间下$ kubectl get secret NAME TYPE DATA AGEdefault-token-dlcmj kubernetes.io/servi 2021-11-24 k8s #运维 #k8s
k8s 集群部署(https) masterapi-server1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253# 创建node节点第一次访问时候的token# 生成随机数$ head -c 16 /dev/urandom | od -An -t x | tr -d ' 2021-11-24 k8s #运维 #k8s
k8sDashboard安装 源码仓库GitHub 版本dashboard v2.0.5 dashboard v2.0.0-beta5 —> kubernetes 1.16dashboard v2.0.0 —> kubernetes 1.18dashboard v2.0.1 —> kubernetes 1.18dashboard v2.0.2 —> kubernetes 1.18dashboard v 2021-11-24 k8s #运维 #k8s
k8syaml kube-apiserver 12345678910111213141516171819# cat /soyuan/k8s/cfg/kube-apiserver-envKUBE_APISERVER_OPTS="--logtostderr=true \--v=4 \--etcd-servers=http://172.16.100.92:2379 \--bind-address=172.16 2021-11-24 k8s #运维 #k8s
k8s二进制文件部署 版本k8s: 1.19 docker:19.03 集群规划 机器 ip 分配节点 172.16.100.92 172.16.100.92 etcd,api-server,kube-controller,kube-scheduler 172.16.100.63 172.16.100.63 docker,kube-proxy,kubelet 172.16.100.64 172.16. 2021-11-24 k8s #运维 #k8s
k8s制作ssl证书 通过ca生成服务器证书12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455# server 证书请求文件$ cat server-csr.json{ "CN": "kubernetes", 2021-11-24 k8s #运维 #k8s
Metricbeat收集系统指标 Metricbeat 部署下载程序123curl -L -O https://artifacts.elastic.co/downloads/beats/metricbeat/metricbeat-7.6.2-darwin-x86_64.tar.gztar xzvf metricbeat-7.6.2-darwin-x86_64.tar.gzcd metricbeat-7.6.2-darwin-x86 2021-11-16 elasticsearch #elasticsearch #开发
elasticsearch部署 ElasticSearch 部署 每个节点可部署到不同的服务器 镜像:elasticsearch:7.6.2 可以配置单机模式 “discovery.type=single-node” 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575 2021-11-10 elasticsearch #elasticsearch #开发