Skip to content

Fix standalone pod crashing when checking for pod owner

Shao Ming Tan requested to merge fix-pod-scan-crash into master

What does this MR do and why?

Fix Operational container crashing when scanning a standalone pod.

How to set up and validate locally

  1. Setup OCS locally

  2. Create a standalone pod

    • kubectl run pingpong --image alpine:3.17.3 ping 1.1.1.1
  3. Start an OCS scan in the default namespace

      container_scanning:
        cadence: '00 * * * *'
        vulnerability_report:
          namespaces:
            - default
            - kube-system
  • The scan should complete successfully without crashing

Linked issue Operational container scanning pod crashes when... (gitlab-org/gitlab#415140 - closed)

Edited by Shao Ming Tan

Merge request reports

Loading