github.com/verrazzano/verrazzano@v1.7.0/platform-operator/thirdparty/charts/rancher/templates/validate-psp-install.yaml (about)

     1  #{{- if gt (len (lookup "rbac.authorization.k8s.io/v1" "ClusterRole" "" "")) 0 -}}
     2  #{{- if .Values.global.cattle.psp.enabled }}
     3  #{{- if not (.Capabilities.APIVersions.Has "policy/v1beta1/PodSecurityPolicy") }}
     4  #{{- fail "The target cluster does not have the PodSecurityPolicy API resource. Please disable PSPs in this chart before proceeding." -}}
     5  #{{- end }}
     6  #{{- end }}
     7  #{{- end -}}