adapt kube-bench scan for containerized k3d
Kube-bench CIS scan / Scan ephemeral K3s cluster (push) Failing after 3m32s
Kube-bench CIS scan / Scan ephemeral K3s cluster (push) Failing after 3m32s
This commit is contained in:
@@ -16,6 +16,11 @@ fails if the scanner job or report generation fails. It does not yet fail on
|
||||
CIS findings because a vanilla K3d cluster is expected to produce findings;
|
||||
later hardening phases can turn selected controls into merge gates.
|
||||
|
||||
Checks 1.4.1 and 1.4.2 are skipped in this CI profile because they require
|
||||
`journalctl`, while the disposable K3d control-plane node runs as a container
|
||||
without a systemd journal. These checks remain relevant for the Flatcar and
|
||||
cloud K3s deployment paths.
|
||||
|
||||
To run the same scan locally against the active K3d cluster:
|
||||
|
||||
```bash
|
||||
|
||||
@@ -28,6 +28,13 @@ spec:
|
||||
- run
|
||||
- --benchmark
|
||||
- k3s-cis-1.7
|
||||
# K3d control-plane nodes run in containers without systemd journals.
|
||||
# These checks require journalctl and are not applicable to this CI topology.
|
||||
- --skip
|
||||
- 1.4.1,1.4.2
|
||||
# CI publishes findings as an artifact. Findings are not a merge gate yet.
|
||||
- --exit-code
|
||||
- "0"
|
||||
- --json
|
||||
securityContext:
|
||||
privileged: true
|
||||
|
||||
Reference in New Issue
Block a user