tuenti / secrets-manager

A daemon to sync Vault secrets to Kubernetes secrets
Apache License 2.0
171 stars 26 forks source link

Secrets-manager unable to start after upgrading to 2.0.0 #85

Closed Sawaphob closed 2 years ago

Sawaphob commented 2 years ago

We are trying to upgrade secrets-manager from version 1.0.1 to 2.0.0. Version 2.0.0 unable to start with below err message. We are using Kubernetes 1.21

E0301 10:05:58.371106 1 runtime.go:78] Observed a panic: "invalid memory address or nil pointer dereference" (runtime error: invalid memory address or nil pointer dereference) goroutine 294 [running]: k8s.io/apimachinery/pkg/util/runtime.logPanic(0x16eefe0, 0x24e1470) /go/pkg/mod/k8s.io/apimachinery@v0.20.2/pkg/util/runtime/runtime.go:74 +0x95 k8s.io/apimachinery/pkg/util/runtime.HandleCrash(0x0, 0x0, 0x0) /go/pkg/mod/k8s.io/apimachinery@v0.20.2/pkg/util/runtime/runtime.go:48 +0x86 panic(0x16eefe0, 0x24e1470) /usr/local/go/src/runtime/panic.go:965 +0x1b9 github.com/tuenti/secrets-manager/controllers.(*SecretDefinitionReconciler).Reconcile(0xc000180a20, 0x1aecd68, 0xc0004791d0, 0xc0003b7140, 0xc, 0xc0003b7120, 0xf, 0xc0004791d0, 0xc000030000, 0x17801c0, ...) /workspace/controllers/secretdefinition_controller.go:240 +0x123 sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).reconcileHandler(0xc00060cdc0, 0x1aeccc0, 0xc00043bdc0, 0x1743f20, 0xc00033a020) /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.8.3/pkg/internal/controller/controller.go:298 +0x30d sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).processNextWorkItem(0xc00060cdc0, 0x1aeccc0, 0xc00043bdc0, 0xc00050f600) /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.8.3/pkg/internal/controller/controller.go:253 +0x205 sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Start.func1.2(0x1aeccc0, 0xc00043bdc0) /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.8.3/pkg/internal/controller/controller.go:216 +0x4a k8s.io/apimachinery/pkg/util/wait.JitterUntilWithContext.func1() /go/pkg/mod/k8s.io/apimachinery@v0.20.2/pkg/util/wait/wait.go:185 +0x37 k8s.io/apimachinery/pkg/util/wait.BackoffUntil.func1(0xc00050f750) /go/pkg/mod/k8s.io/apimachinery@v0.20.2/pkg/util/wait/wait.go:155 +0x5f k8s.io/apimachinery/pkg/util/wait.BackoffUntil(0xc000a41f50, 0x1abb220, 0xc000479170, 0xc00043bd01, 0xc0004fe600) /go/pkg/mod/k8s.io/apimachinery@v0.20.2/pkg/util/wait/wait.go:156 +0x9b k8s.io/apimachinery/pkg/util/wait.JitterUntil(0xc00050f750, 0x3b9aca00, 0x0, 0x3b9aca01, 0xc0004fe600) /go/pkg/mod/k8s.io/apimachinery@v0.20.2/pkg/util/wait/wait.go:133 +0x98 k8s.io/apimachinery/pkg/util/wait.JitterUntilWithContext(0x1aeccc0, 0xc00043bdc0, 0xc0003c7770, 0x3b9aca00, 0x0, 0x100000000000001) /go/pkg/mod/k8s.io/apimachinery@v0.20.2/pkg/util/wait/wait.go:185 +0xa6 k8s.io/apimachinery/pkg/util/wait.UntilWithContext(0x1aeccc0, 0xc00043bdc0, 0xc0003c7770, 0x3b9aca00) /go/pkg/mod/k8s.io/apimachinery@v0.20.2/pkg/util/wait/wait.go:99 +0x57 created by sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Start.func1 /go/pkg/mod/sigs.k8s.io/controller-runtime@v0.8.3/pkg/internal/controller/controller.go:213 +0x40d panic: runtime error: invalid memory address or nil pointer dereference [recovered] panic: runtime error: invalid memory address or nil pointer dereference [signal SIGSEGV: segmentation violation code=0x1 addr=0x30 pc=0x15b4c83]