Uploaded image for project: 'OpenShift Bugs'
  1. OpenShift Bugs
  2. OCPBUGS-7949

Webhook Secret (1 of 2) is not removed when Knative Service is deleted

XMLWordPrintable

    • Low
    • No
    • 2
    • ODC Sprint 232, ODC Sprint 234, ODC Sprint 235
    • 3
    • Rejected
    • False
    • Hide

      None

      Show
      None
    • Hide
      * Previously, when you deleted a Knative (`kn`) service on the OpenShift web console, the associated `<kn-service-name>-github-webhook-secret` webhook was not deleted. If you attempted to recreate the Knative service, while retraining the same name as the original service, the operation would fail. With this update, when you delete a Knative (`kn`) service on the OpenShift web console, the associated webhook is deleted at the same time as the service. You can now recreate a Knative service with the same name as the deleted service without the operation failing. (link:https://issues.redhat.com/browse/OCPBUGS-7949[*OCPBUGS-7949*])
      Show
      * Previously, when you deleted a Knative (`kn`) service on the OpenShift web console, the associated `<kn-service-name>-github-webhook-secret` webhook was not deleted. If you attempted to recreate the Knative service, while retraining the same name as the original service, the operation would fail. With this update, when you delete a Knative (`kn`) service on the OpenShift web console, the associated webhook is deleted at the same time as the service. You can now recreate a Knative service with the same name as the deleted service without the operation failing. (link: https://issues.redhat.com/browse/OCPBUGS-7949 [* OCPBUGS-7949 *])
    • Bug Fix
    • Done

      This is a clone of issue OCPBUGS-7437. The following is the description of the original issue:

      This is a clone of issue OCPBUGS-5547. The following is the description of the original issue:

      Description of problem:
      This is a follow-up on https://bugzilla.redhat.com/show_bug.cgi?id=2083087 and https://github.com/openshift/console/pull/12390

      When creating a Knative Service and delete it again with enabled option "Delete other resources created by console" (only available on 4.13+ with the PR above) the secret "$name-github-webhook-secret" is not deleted.

      When the user tries to create the same Knative Service again this fails with an error:

      An error occurred
      secrets "nodeinfo-github-webhook-secret" already exists
      

      Version-Release number of selected component (if applicable):
      4.13

      (we might want to backport this together with https://github.com/openshift/console/pull/12390 and OCPBUGS-5548)

      How reproducible:
      Always

      Steps to Reproduce:

      1. Install OpenShift Serverless operator (tested with 1.26.0)
      2. Create a new project
      3. Navigate to Add > Import from git and create an application
      4. In the topology select the Knative Service > "Delete Service" (not Delete App)

      Actual results:
      Deleted resources:

      1. Knative Service (tries it twice!) $name
      2. ImageStream $name
      3. BuildConfig $name
      4. Secret $name-generic-webhook-secret

      Expected results:
      Should also remove this resource

      1. Delete Knative Service should be called just once
      2. Secret $name-github-webhook-secret

      Additional info:
      When delete the whole application all the resources are deleted correctly (and just once)!

      1. Knative Service (just once!) $name
      2. ImageStream $name
      3. BuildConfig $name
      4. Secret $name-generic-webhook-secret
      5. Secret $name-github-webhook-secret

              avik6028 Avik Kundu
              openshift-crt-jira-prow OpenShift Prow Bot
              Sanket Pathak Sanket Pathak
              Darragh Fitzmaurice Darragh Fitzmaurice
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Created:
                Updated:
                Resolved: