.rules accessor error on changing networking layer for Knative Serving

30 Views Asked by At

Describe the bug On moving away from Contour to Kourier for networking layer, Knative Serving cannot be reconciled due to the follow error.

{"severity":"ERROR","timestamp":"2023-07-12T19:21:03.858540009Z","logger":"knative-operator","caller":"controller/controller.go:566","message":"Reconcile error","commit":"ff7e841-dirty","knative.dev/pod":"knative-operator-7b56d8c589-qrglj","knative.dev/controller":"knative.dev.operator.pkg.reconciler.knativeserving.Reconciler","knative.dev/kind":"operator.knative.dev.KnativeServing","knative.dev/traceid":"b3490531-8a0b-400e-8546-c20ac6a1d547","knative.dev/key":"knative-serving/knative-serving","duration":"36.766091ms","error":".rules accessor error: <nil> is of the type <nil>, expected []interface{}","stacktrace":"knative.dev/pkg/controller.(*Impl).handleErr\n\tknative.dev/[email protected]/controller/controller.go:566\nknative.dev/pkg/controller.(*Impl).processNextWorkItem\n\tknative.dev/[email protected]/controller/controller.go:543\nknative.dev/pkg/controller.(*Impl).RunContext.func3\n\tknative.dev/[email protected]/controller/controller.go:491"}
{"severity":"INFO","timestamp":"2023-07-12T19:21:03.858665466Z","logger":"knative-operator.event-broadcaster","caller":"record/event.go:285","message":"Event(v1.ObjectReference{Kind:\"KnativeServing\", Namespace:\"knative-serving\", Name:\"knative-serving\", UID:\"479b26af-a4f8-43f0-a490-1481874e89b8\", APIVersion:\"operator.knative.dev/v1beta1\", ResourceVersion:\"1873540919\", FieldPath:\"\"}): type: 'Warning' reason: 'InternalError' .rules accessor error: <nil> is of the type <nil>, expected []interface{}","commit":"ff7e841-dirty","knative.dev/pod":"knative-operator-7b56d8c589-qrglj"}

Unable to obtain the installed manifest; obsolete resources may linger.rules accessor error: <nil> is of the type <nil>, expected []interface{}

Expected behavior Contour controller scaled down, and Kourier components deployed.

To Reproduce Have not been able to reliably reproduce in a different environment.

Knative release version v1.10

Additional context Following is my KnativeServing CRD. Prior to this, it was spec.ingress.contour.enabled: true and spec.config.network.ingress-class: "contour.ingress.networking.knative.dev". Following this change, the aforementioned error repeats even on reverting the change and attempting to restore contour use. I have also attempted deleting the entire Knative stack and redeploying, with similar results.

apiVersion: operator.knative.dev/v1beta1
kind: KnativeServing
metadata:
  name: knative-serving
  namespace: knative-serving
spec:
  version: "1.10"
  ingress:
    kourier:
      enabled: true
  config:
    deployment:
      max-non-active-revisions: "1"
      min-non-active-revisions: "1"
    network:
      ingress-class: "kourier.ingress.networking.knative.dev"
    autoscaler:
      pod-autoscaler-class: "kpa.autoscaling.knative.dev"
      enable-scale-to-zero: "true"
0

There are 0 best solutions below