k8s-operator指北

0. 参考

0.1 operator-sdk、k8s-controller、operator

https://www.tailored.cloud/kubernetes/write-a-kubernetes-controller-operator-sdk/
https://github.com/cnych/opdemo
https://www.tailored.cloud/kubernetes/simple-custom-kubernetes-controller/

https://github.com/bitnami-labs/kubewatch

k8s控制器写法
https://github.com/piontec/k8s-demo-controller

写k8s 用户自定义controller.
https://medium.com/@cloudark/kubernetes-custom-controllers-b6c7d0668fdf
https://engineering.bitnami.com/articles/kubewatch-an-example-of-kubernetes-custom-controller.html
https://engineering.bitnami.com/articles/a-deep-dive-into-kubernetes-controllers.html
https://github.com/double12gzh/k8s-controller-demo.git
https://github.com/kubernetes/sample-controller/blob/master/docs/controller-client-go.md

https://medium.com/@cloudark/kubernetes-operators-when-how-and-the-gotchas-to-keep-in-mind-b13be9830346

controller代码理解

1. operator-sdk

1.1. 实战(operator-sdk)

https://github.com/operator-framework/operator-sdk/blob/master/doc/user-guide.md#add-a-new-custom-resource-definition
https://www.qikqiak.com/post/k8s-operator-101/

1.2. 如何本地远程调试服务器上的Operator

a. 在服务器上执行export WATCH_NAMESPACE=default
b. 在服务器上执行dlv --listen=:2345 --headless=true --api-version=2 exec ./build/_output/bin/lanjie-operator-local --check-go-version=false --
c. 设置goland

2. kubebuilder

2.1 实战(kubebuilder)

posted @ 2020-03-18 22:16  大海星  阅读(1386)  评论(0编辑  收藏  举报