From c9ed2c8a858a0867c2f09ed8b5a33f2d209e3d22 Mon Sep 17 00:00:00 2001 From: krishbajaj1609 Date: Wed, 5 Jun 2024 12:20:28 +0530 Subject: [PATCH] feature/global-policy-set : upgrade version for test --- charts/test-krish-globalps/Chart.yaml | 2 +- .../pols/disallow-host-ports.yaml | 40 ------------------- 2 files changed, 1 insertion(+), 41 deletions(-) delete mode 100644 charts/test-krish-globalps/pols/disallow-host-ports.yaml diff --git a/charts/test-krish-globalps/Chart.yaml b/charts/test-krish-globalps/Chart.yaml index 835d756e..5d74dfcd 100644 --- a/charts/test-krish-globalps/Chart.yaml +++ b/charts/test-krish-globalps/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v2 name: test-krish description: Pod Security Standards (baseline) policy set type: application -version: 0.6.14 +version: 0.6.15 appVersion: 0.1.0 keywords: - kubernetes diff --git a/charts/test-krish-globalps/pols/disallow-host-ports.yaml b/charts/test-krish-globalps/pols/disallow-host-ports.yaml deleted file mode 100644 index b007f6eb..00000000 --- a/charts/test-krish-globalps/pols/disallow-host-ports.yaml +++ /dev/null @@ -1,40 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: disallow-host-ports - annotations: - policies.kyverno.io/title: Disallow hostPorts - policies.kyverno.io/category: Pod Security Standards (Baseline) - policies.kyverno.io/severity: medium - policies.kyverno.io/subject: Pod - kyverno.io/kubernetes-version: "1.22-1.23" - policies.nirmata.io/remediation-docs: "https://docs.nirmata.io/policysets/podsecurity/baseline/disallow-host-ports/" - policies.nirmata.io/remediation: "https://github.com/nirmata/kyverno-policies/tree/main/pod-security/baseline/disallow-host-ports/remediate-disallow-host-ports.yaml" - policies.kyverno.io/description: >- - Access to host ports allows potential snooping of network traffic and should not be - allowed, or at minimum restricted to a known list. This policy ensures the `hostPort` - field is unset or set to `0`. -spec: - validationFailureAction: Audit - background: true - rules: - - name: host-ports-none - match: - any: - - resources: - kinds: - - Pod - validate: - message: >- - Use of host ports is disallowed. - pattern: - spec: - =(ephemeralContainers): - - =(ports): - - =(hostPort): 0 - =(initContainers): - - =(ports): - - =(hostPort): 0 - containers: - - =(ports): - - =(hostPort): 0