Closed rfyiamcool closed 1 year ago
@rfyiamcool Thanks for your contribution, this sounds really reasonable. Can you help to fix the lint error?
😅 I run unit test successfully locally,i don't know why test fail.
Running tool: /usr/local/go/bin/go test -timeout 120s -run ^TestNamespace$ github.com/RocksLabs/kvrocks_controller/server -v -count=1
=== RUN TestNamespace
=== RUN TestNamespace/Create_namespace
=== RUN TestNamespace/Create_duplicate_namespace
=== RUN TestNamespace/List_namespaces
=== RUN TestNamespace/Delete_namespace
--- PASS: TestNamespace (0.61s)
--- PASS: TestNamespace/Create_namespace (0.23s)
--- PASS: TestNamespace/Create_duplicate_namespace (0.11s)
--- PASS: TestNamespace/List_namespaces (0.11s)
--- PASS: TestNamespace/Delete_namespace (0.15s)
PASS
ok github.com/RocksLabs/kvrocks_controller/server 0.833s
Thanks @rfyiamcool, I will have a look later.
change
When deploying multiple instances, we usually use the same configuration file, but the IP address of each instance is different, so we need to get local addr dynamically.
in addition, when using k8s to deploy
kvrocks-controller
, we can directly inject pod information into the environment variables of the container.https://kubernetes.io/zh-cn/docs/tasks/inject-data-application/environment-variable-expose-pod-information/