operator
operator copied to clipboard
TargetNamespace lifecycle is not handled properly in TektonPipelines reconciler
Expected Behavior
A delete and recreate of TektonPipelines works smoothly.
Actual Behavior
When we delete and recreate TektonPipelines, its resources doesnot get created. The logs are added in the 'Additional Info' section below.
Additional Info
{"level":"error","logger":"tekton-operator-lifecycle","caller":"common/prune.go:133","msg":"failed to create cronjob cronjobs.batch \"tekton-resource-prun
er-rnl6g\" is forbidden: unable to create new content in namespace tekton-pipelines because it is being terminated","knative.dev/pod":"tekton-operator-6c85cb7db-4k7q5","knative.dev/controller":"github.com.tektoncd.operator.pkg.reconciler.shared.tektonconfig.Reconciler","knative.dev/kind":"operator.tekton.dev.TektonConfig","knative.dev/traceid":"ff01eb54-ea1b-49db-9a41-496cae333d7c","knative.dev/key":"config","stacktrace":"github.com/tektoncd/operator/pkg/reconciler/common.Prune\n\tgithub.com/tektoncd/operator/pkg/reconciler/common/prune.go:133\ngithub.com/tektoncd/operator/pkg/reconciler/shared/tektonconfig.(*Reconciler).ReconcileKind\n\tgithub.com/tektoncd/operator/pkg/reconciler/shared/tektonconfig/tektonconfig.go:136\ngithub.com/tektoncd/operator/pkg/client/injection/reconciler/operator/v1alpha1/tektonconfig.(*reconcilerImpl).Reconcile\n\tgithub.com/tektoncd/operator/pkg/client/injection/reconciler/operator/v1alpha1/tektonconfig/reconciler.go:235\nknative.dev/pkg/controller.(*Impl).processNextWorkItem\n\tknative.dev/[email protected]/controller/controller.go:542\nknative.dev/pkg/controller.(*Impl).RunContext.func3\n\tknative.dev/[email protected]/controller/controller.go:478"}
{"level":"error","logger":"tekton-operator-lifecycle","caller":"tektonconfig/tektonconfig.go:151","msg":"unable to parse requirement: <nil>: Invalid value: \"operator.tekton.dev/targetNamespace/mark-for-deletion\": a qualified name must consist of alphanumeric characters, '-', '_' or '.', and must start and end with an alphanumeric character (e.g. 'MyName', or 'my.name', or '123-abc', regex used for validation is '([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]') with an optional DNS subdomain prefix and '/' (e.g. 'example.com/MyName')","knative.dev/pod":"tekton-operator-6c85cb7db-4k7q5","knative.dev/controller":"github.com.tektoncd.operator.pkg.reconciler.shared.tektonconfig.Reconciler","knative.dev/kind":"operator.tekton.dev.TektonConfig","knative.dev/traceid":"f
f01eb54-ea1b-49db-9a41-496cae333d7c","knative.dev/key":"config","stacktrace":"github.com/tektoncd/operator/pkg/reconciler/shared/tektonconfig.(*Reconciler
).ReconcileKind\n\tgithub.com/tektoncd/operator/pkg/reconciler/shared/tektonconfig/tektonconfig.go:151\ngithub.com/tektoncd/operator/pkg/client/injection/
reconciler/operator/v1alpha1/tektonconfig.(*reconcilerImpl).Reconcile\n\tgithub.com/tektoncd/operator/pkg/client/injection/reconciler/operator/v1alpha1/te
ktonconfig/reconciler.go:235\nknative.dev/pkg/controller.(*Impl).processNextWorkItem\n\tknative.dev/[email protected]/controller/cont
roller.go:542\nknative.dev/pkg/controller.(*Impl).RunContext.func3\n\tknative.dev/[email protected]/controller/controller.go:478"}
Steps to Reproduce the Problem
- Install operator and let TektonConfig instance reach status Ready: true
- Delete tektonpipelines instance
- wait from TekonPipelines to comeback up
ran into the same/similar issue...
workaround that worked for me: k delete ns tekton-operator then reinstall the operator
Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale with a justification.
Stale issues rot after an additional 30d of inactivity and eventually close.
If this issue is safe to close now please do so with /close with a justification.
If this issue should be exempted, mark the issue as frozen with /lifecycle frozen with a justification.
/lifecycle stale
Send feedback to tektoncd/plumbing.
Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten with a justification.
Rotten issues close after an additional 30d of inactivity.
If this issue is safe to close now please do so with /close with a justification.
If this issue should be exempted, mark the issue as frozen with /lifecycle frozen with a justification.
/lifecycle rotten
Send feedback to tektoncd/plumbing.
Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen with a justification.
Mark the issue as fresh with /remove-lifecycle rotten with a justification.
If this issue should be exempted, mark the issue as frozen with /lifecycle frozen with a justification.
/close
Send feedback to tektoncd/plumbing.
@tekton-robot: Closing this issue.
In response to this:
Rotten issues close after 30d of inactivity. Reopen the issue with
/reopenwith a justification. Mark the issue as fresh with/remove-lifecycle rottenwith a justification. If this issue should be exempted, mark the issue as frozen with/lifecycle frozenwith a justification./close
Send feedback to tektoncd/plumbing.
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.