apiVersion : kyverno.io/v1
kind: ClusterPolicy
metadata:
  name: check-node-port
spec:
  rules:
  - name: check-node-port
    match:
      resources:
        kinds:
        - Service
    validate:
      message: "NodePort type is not allowed"
      pattern:
        spec:
          type: "!NodePort"
