Interview Prep/DevSecOps/DAST, runtime detection and compliance scans

The kube-bench job completes but most checks show `WARN` or "unable to find config file"

IntermediateTroubleshootingDAST, runtime detection and compliance scans
Answer

Likely causes → The job does not mount the host paths where the kubelet config lives, or the distribution uses non-standard paths (k3s, RKE2, Bottlerocket), or version auto-detection picked the wrong benchmark.

Diagnose → kubectl logs job/kube-bench | head -30, and check the job's volumeMounts against where the kubelet config actually lives on the node (ps -ef | grep kubelet).

Fix → Use the distribution-specific job manifest, or pass the right config with --benchmark and --config-dir, and mount /var/lib/kubelet and /etc/kubernetes read-only. On Bottlerocket, use the OS's own CIS reporting.

Prevent → Fail the compliance job when the WARN count passes a threshold, so a broken scan is not mistaken for a clean one.

All DevSecOps questions Roadmap: Policy as code

More on DAST, runtime detection and compliance scans