Uploaded image for project: 'Knative Serving'
  1. Knative Serving
  2. SRVKS-640

SinkBinding doesn't update ksvc if have name given

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Do
    • Icon: Minor Minor
    • None
    • 1.9.0, 1.10.0, 1.11.0, 1.12.0, 1.13.0, 1.14.0, 1.15.0, 1.16.0, 1.17.0
    • None
    • False
    • False
    • Undefined

      Description

      Webhook fails to update Kservice with K_SINK and K_CE_OVERRIDES environmental variables, if Knative service has name given. This is often the case as Knative CLI create such resource.

      The error:

      Saw the following changes without a name change (-old +new): spec.template.metadata.name
      {*v1.RevisionTemplateSpec}.Spec.PodSpec.Containers[0].Env[?->1]:
      	+: v1.EnvVar: "{Name:K_SINK Value:http://broker-ingress.knative-eventing.svc.cluster.local/demo/default ValueFrom:nil}"
      {*v1.RevisionTemplateSpec}.Spec.PodSpec.Containers[0].Env[?->2]:
      	+: v1.EnvVar: "{Name:K_CE_OVERRIDES Value: ValueFrom:nil}"
      

      The Kservice was created by:

      kn service create showcase \
        --image quay.io/cardil/knative-serving-showcase:2-send-event
      

      The Knative definition webhook-error.sink-1.ksvc.yaml
      The SinkBinding definition webhook-error.sink-1.sb.yaml

      Reproduction

      1. Deploy a ksvc via kn
      2. Create a sinkbinding to it

      Expected

      SinkBinding should update ksvc and set K_SINK and K_CE_OVERRIDES environmental variables

      Actual

      The above error can be seen in webhook (knative-serving namespace) logs

              Unassigned Unassigned
              krzysztofsuszynski Chris Suszynski
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: