Closed jimmykirk closed 3 years ago
Has this been tested in 1.11?
21:51:02 $> kubectl version Client Version: version.Info{Major:"1", Minor:"11", GitVersion:"v1.11.0", GitCommit:"91e7b4fd31fcd3d5f436da26c980becec37ceefe", GitTreeState:"clean", BuildDate:"2018-06-27T20:17:28Z", GoVersion:"go1.10.2", Compiler:"gc", Platform:"linux/amd64"} Server Version: version.Info{Major:"1", Minor:"11", GitVersion:"v1.11.1", GitCommit:"b1b29978270dc22fecc592ac55d903350454310a", GitTreeState:"clean", BuildDate:"2018-07-17T18:43:26Z", GoVersion:"go1.10.3", Compiler:"gc", Platform:"linux/amd64"}
I get all kinds of errors when trying to configure things.
I0804 02:59:57.570110 1 main.go:64] Using build: v0.1.4-1-gb9100f5 I0804 02:59:57.618685 1 main.go:98] Current configuration: Controller: &config.ControllerConfig{ConsulAddress:"consul-0.consul.default.svc.cluster.local", ConsulPort:"8500", ConsulScheme:"http", ConsulCAFile:"", ConsulCertFile:"", ConsulKeyFile:"", ConsulInsecureSkipVerify:false, ConsulToken:"", ConsulTimeout:2000000000, ConsulContainerName:"consul", ConsulNodeSelector:"consul=enabled", PodLabelSelector:"consul", K8sTag:"kubernetes", RegisterMode:"node"}, Consul: &api.Config{Address:"127.0.0.1:8500", Scheme:"http", Datacenter:"", HttpClient:(http.Client)(0xc4203fe2a0), HttpAuth:(api.HttpBasicAuth)(nil), WaitTime:0, Token:""} I0804 02:59:57.618862 1 main.go:128] Start syncing... I0804 02:59:57.629461 1 main.go:133] Synchronization's been ended I0804 02:59:57.629522 1 main.go:112] Start cleaning... E0804 02:59:57.635773 1 reflector.go:300] github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/reflector.go:94: Failed to watch *v1.Pod: unknown (get pods) I0804 02:59:57.641457 1 main.go:117] Cleaning has been ended I0804 02:59:58.649738 1 controller.go:262] Skip pod nats-1. Label selector is consul, pod's labels: map[string]string{"controller-revision-hash":"nats-5849b8f87b", "statefulset.kubernetes.io/pod-name":"nats-1", "component":"nats"} E0804 02:59:58.650076 1 runtime.go:64] Observed a panic: "index out of range" (runtime error: index out of range) /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/runtime/runtime.go:70 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/runtime/runtime.go:63 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/runtime/runtime.go:49 /usr/local/go/src/runtime/asm_amd64.s:479 /usr/local/go/src/runtime/panic.go:458 /usr/local/go/src/runtime/panic.go:27 /root/gopath/src/github.com/tczekajlo/kube-consul-register/utils/utils.go:39 /root/gopath/src/github.com/tczekajlo/kube-consul-register/controller/controller.go:260 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:180 :51 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:246 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/delta_fifo.go:420 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:131 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:102 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/wait/wait.go:96 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/wait/wait.go:97 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/wait/wait.go:52 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:102 /root/gopath/src/github.com/tczekajlo/kube-consul-register/controller/controller.go:273 /root/gopath/src/github.com/tczekajlo/kube-consul-register/main.go:141 /usr/local/go/src/runtime/asm_amd64.s:2086 E0804 02:59:58.650325 1 runtime.go:64] Observed a panic: "index out of range" (runtime error: index out of range) /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/runtime/runtime.go:70 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/runtime/runtime.go:63 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/runtime/runtime.go:49 /usr/local/go/src/runtime/asm_amd64.s:479 /usr/local/go/src/runtime/panic.go:458 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/runtime/runtime.go:56 /usr/local/go/src/runtime/asm_amd64.s:479 /usr/local/go/src/runtime/panic.go:458 /usr/local/go/src/runtime/panic.go:27 /root/gopath/src/github.com/tczekajlo/kube-consul-register/utils/utils.go:39 /root/gopath/src/github.com/tczekajlo/kube-consul-register/controller/controller.go:260 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:180 :51 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:246 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/delta_fifo.go:420 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:131 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:102 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/wait/wait.go:96 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/wait/wait.go:97 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/wait/wait.go:52 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:102 /root/gopath/src/github.com/tczekajlo/kube-consul-register/controller/controller.go:273 /root/gopath/src/github.com/tczekajlo/kube-consul-register/main.go:141 /usr/local/go/src/runtime/asm_amd64.s:2086 panic: runtime error: index out of range [recovered] panic: runtime error: index out of range [recovered] panic: runtime error: index out of range goroutine 84 [running]: panic(0x119d320, 0xc420012070) /usr/local/go/src/runtime/panic.go:500 +0x1a1 github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/runtime.HandleCrash(0x0, 0x0, 0x0) /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/runtime/runtime.go:56 +0x126 panic(0x119d320, 0xc420012070) /usr/local/go/src/runtime/panic.go:458 +0x243 github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/runtime.HandleCrash(0x0, 0x0, 0x0) /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/runtime/runtime.go:56 +0x126 panic(0x119d320, 0xc420012070) /usr/local/go/src/runtime/panic.go:458 +0x243 github.com/tczekajlo/kube-consul-register/utils.HasLabel(0xc42028c4e0, 0xc42051629a, 0x6, 0x7fcd4735f180) /root/gopath/src/github.com/tczekajlo/kube-consul-register/utils/utils.go:39 +0x1e0 github.com/tczekajlo/kube-consul-register/controller.(*Controller).Watch.func3(0x12e4700, 0xc420585d90, 0x12e4700, 0xc42065e2b0) /root/gopath/src/github.com/tczekajlo/kube-consul-register/controller/controller.go:260 +0x12a github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache.ResourceEventHandlerFuncs.OnUpdate(0x13b95b8, 0xc420581760, 0xc420581750, 0x12e4700, 0xc420585d90, 0x12e4700, 0xc42065e2b0) /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:180 +0x5d github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache.(*ResourceEventHandlerFuncs).OnUpdate(0xc4200632c0, 0x12e4700, 0xc420585d90, 0x12e4700, 0xc42065e2b0) :51 +0x8c github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache.NewInformer.func1(0x11b58e0, 0xc4207355c0, 0xc4207355c0, 0x11b58e0) /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:246 +0x335 github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache.(*DeltaFIFO).Pop(0xc4200dcb00, 0xc4204f4ed0, 0x0, 0x0, 0x0, 0x0) /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/delta_fifo.go:420 +0x22a github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache.(*Controller).processLoop(0xc4204dc0e0) /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:131 +0x3c github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache.(*Controller).(github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache.processLoop)-fm() /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:102 +0x2a github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/wait.JitterUntil.func1(0xc42013fe80) /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/wait/wait.go:96 +0x5e github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/wait.JitterUntil(0xc42013fe80, 0x3b9aca00, 0x0, 0x1119401, 0xc4200c2120) /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/wait/wait.go:97 +0xad github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/wait.Until(0xc42013fe80, 0x3b9aca00, 0xc4200c2120) /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/wait/wait.go:52 +0x4d github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache.(*Controller).Run(0xc4204dc0e0, 0xc4200c2120) /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:102 +0x1af github.com/tczekajlo/kube-consul-register/controller.(*Controller).Watch(0xc42058c580) /root/gopath/src/github.com/tczekajlo/kube-consul-register/controller/controller.go:273 +0x323 main.main.func3(0x1ab29c0, 0xc42058c580) /root/gopath/src/github.com/tczekajlo/kube-consul-register/main.go:141 +0x31 created by main.main /root/gopath/src/github.com/tczekajlo/kube-consul-register/main.go:142 +0x51e
I0804 02:59:57.570110 1 main.go:64] Using build: v0.1.4-1-gb9100f5 I0804 02:59:57.618685 1 main.go:98] Current configuration: Controller: &config.ControllerConfig{ConsulAddress:"consul-0.consul.default.svc.cluster.local", ConsulPort:"8500", ConsulScheme:"http", ConsulCAFile:"", ConsulCertFile:"", ConsulKeyFile:"", ConsulInsecureSkipVerify:false, ConsulToken:"", ConsulTimeout:2000000000, ConsulContainerName:"consul", ConsulNodeSelector:"consul=enabled", PodLabelSelector:"consul", K8sTag:"kubernetes", RegisterMode:"node"}, Consul: &api.Config{Address:"127.0.0.1:8500", Scheme:"http", Datacenter:"", HttpClient:(http.Client)(0xc4203fe2a0), HttpAuth:(api.HttpBasicAuth)(nil), WaitTime:0, Token:""} I0804 02:59:57.618862 1 main.go:128] Start syncing... I0804 02:59:57.629461 1 main.go:133] Synchronization's been ended I0804 02:59:57.629522 1 main.go:112] Start cleaning... E0804 02:59:57.635773 1 reflector.go:300] github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/reflector.go:94: Failed to watch *v1.Pod: unknown (get pods) I0804 02:59:57.641457 1 main.go:117] Cleaning has been ended I0804 02:59:58.649738 1 controller.go:262] Skip pod nats-1. Label selector is consul, pod's labels: map[string]string{"controller-revision-hash":"nats-5849b8f87b", "statefulset.kubernetes.io/pod-name":"nats-1", "component":"nats"} E0804 02:59:58.650076 1 runtime.go:64] Observed a panic: "index out of range" (runtime error: index out of range) /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/runtime/runtime.go:70 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/runtime/runtime.go:63 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/pkg/util/runtime/runtime.go:49 /usr/local/go/src/runtime/asm_amd64.s:479 /usr/local/go/src/runtime/panic.go:458 /usr/local/go/src/runtime/panic.go:27 /root/gopath/src/github.com/tczekajlo/kube-consul-register/utils/utils.go:39 /root/gopath/src/github.com/tczekajlo/kube-consul-register/controller/controller.go:260 /root/gopath/src/github.com/tczekajlo/kube-consul-register/vendor/k8s.io/client-go/tools/cache/controller.go:180
@jimmykirk No, I've never tested the tool on k8s v1.11.
It is working in Kubernetes 1.19.0
Has this been tested in 1.11?
I get all kinds of errors when trying to configure things.