目录
3.Chaos Mesh - 让应用跟混沌在 Kubernetes 上共舞
1.混沌网格(Chaos Mesh)的设计和工作原理
https://www.kubernetes.org.cn/7443.html
2.官方文档
3.Chaos Mesh - 让应用跟混沌在 Kubernetes 上共舞
https://pingcap.com/blog-cn/chaos-mesh/
4.crd的运行必须有对应的控制器
5.创建crd资源
kubectl apply -f xxx
6.如何查看crd资源?
kubectl get crds
7.文档:
Chaos Mesh - 让应用跟混沌在 Kubernetes 上共舞:https://pingcap.com/blog-cn/chaos-mesh/
混沌网格(Chaos Mesh)的设计和工作原理:https://www.kubernetes.org.cn/7443.html
helm官方文档:https://www.kubernetes.org.cn/7443.html
Kuberneters(K8s)CRD资源详解:https://www.jianshu.com/p/cc7eea6dd1fb
chaos mesh官方文档:https://chaos-mesh.org/docs/development_guides/develop_a_new_chaos/
https://github.com/chaos-mesh/chaos-mesh
https://www.bilibili.com/video/BV1vZ4y137eT?from=search&seid=14287874291108213174
https://github.com/MistShi/chaos-mesh
helm学习:https://shanyue.tech/k8s/helm.html
helm官方文档:https://helm.sh/zh/docs/faq/
k8s标签讲解:https://kubernetes.io/zh/docs/concepts/overview/working-with-objects/common-labels/
玩helm不得不会的helm:https://zhuanlan.zhihu.com/p/79046244
operator:https://coreos.com/operators/
operator:http://dockone.io/article/8769
使用 helm 部署 k8s 资源:https://juejin.cn/post/6844903986496012301
kubectl create和kubectl apply区别:https://www.yuque.com/simonalong/ruanjian/dlml8m
8.helm v3没有--name参数
可通过helm install --help查看可用参数;
执行install,eg:
由
helm install helm/chaos-mesh --name=chaos-mesh --namespace=chaos-testing
会报:Error: unknown flag: --name
变为:
helm install chaos-mesh helm/chaos-mesh --namespace=chaos-testing
9.超看pod的标签:
https://blog.csdn.net/qq_37377136/article/details/108556188
10.演练:
step1:跟本地安装helm,安装helm v3,集client和Server(Tiller)于一体;helm version 查看版本;
step2:安装chaos mesh到k8s集群上;方式:git clone 下拉chaos mesh,然后apply -f(创建 CRD 资源),最后用helm安装,helm install 名字 xxxxxxxxxx;
step3:检查chaos mesh状态:kubectl get pods --namespace chaos-testing -l app.kubernetes.io/instance=chaos-mesh
step4:投放异常;编写pod-kill行为的yaml,然后apply -f ,之后观察异常是否符合预期;开头:apiVersion: chaos-mesh.org/v1alpha1
kind: PodChaos
step5:删除资源;kubectl delete -f xxx.yaml
11.