From 564a49c26a099e46e3f4fb11a3417c811c845eda Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Charles-Edouard=20Br=C3=A9t=C3=A9ch=C3=A9?= Date: Mon, 7 Oct 2024 23:35:18 +0200 Subject: [PATCH] fix: disallow-privilege-escalation (cel) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Charles-Edouard Brétéché --- .../.chainsaw-test/chainsaw-test.yaml | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/pod-security-cel/restricted/disallow-privilege-escalation/.chainsaw-test/chainsaw-test.yaml b/pod-security-cel/restricted/disallow-privilege-escalation/.chainsaw-test/chainsaw-test.yaml index 4298a819d..d59a2bbec 100755 --- a/pod-security-cel/restricted/disallow-privilege-escalation/.chainsaw-test/chainsaw-test.yaml +++ b/pod-security-cel/restricted/disallow-privilege-escalation/.chainsaw-test/chainsaw-test.yaml @@ -2,7 +2,6 @@ apiVersion: chainsaw.kyverno.io/v1alpha1 kind: Test metadata: - creationTimestamp: null name: disallow-privilege-escalation spec: # disable templating because it can cause issues with CEL expressions @@ -10,7 +9,7 @@ spec: steps: - name: step-01 try: - - apply: + - create: file: ../disallow-privilege-escalation.yaml - patch: resource: @@ -24,16 +23,16 @@ spec: file: policy-ready.yaml - name: step-02 try: - - apply: + - create: file: pod-good.yaml - - apply: + - create: expect: - check: ($error != null): true file: pod-bad.yaml - - apply: + - create: file: podcontroller-good.yaml - - apply: + - create: expect: - check: ($error != null): true