This policy ensures that the name of the ApplicationSet is the same value provided in the project.
apiVersion: kyverno.io/v1kind: ClusterPolicymetadata:name: applicationset-name-matches-projectannotations:policies.kyverno.io/title: Ensure ApplicationSet Name Matches Project in CEL expressionspolicies.kyverno.io/category: Argo in CELpolicies.kyverno.io/severity: mediumkyverno.io/kyverno-version: 1.11.0policies.kyverno.io/minversion: 1.11.0kyverno.io/kubernetes-version: 1.26-1.27policies.kyverno.io/subject: ApplicationSetpolicies.kyverno.io/description: This policy ensures that the name of the ApplicationSet is the same value provided in the project.spec:validationFailureAction: Auditbackground: truerules:- name: match-namematch:any:- resources:kinds:- ApplicationSetoperations:- CREATE- UPDATEvalidate:cel:expressions:- expression: object.spec.template.spec.project == object.metadata.namemessage: The name must match the project.
This policy prevents the use of the default project in an Application.
Services of type LoadBalancer when deployed inside AWS have support for transport encryption if it is enabled via an annotation. This policy requires that Services of type LoadBalancer contain the annotation service.beta.kubernetes.io/aws-load-balancer-ssl-cert with some value.
This policy prevents updates to the project field after an Application is created.