argo-cd/resource_customizations/policy.open-cluster-management.io/ConfigurationPolicy/testdata/progressing.yaml
Justin Kulikauskas d2231577c7
feat: Add open-cluster-management.io healthchecks (#19411)
Healthchecks for several Policy types.

Signed-off-by: Justin Kulikauskas <jkulikau@redhat.com>
2024-08-13 15:38:30 -04:00

61 lines
1.7 KiB
YAML

apiVersion: policy.open-cluster-management.io/v1
kind: ConfigurationPolicy
metadata:
name: policy-namespace
generation: 3
namespace: local-cluster
spec:
object-templates:
- complianceType: musthave
objectDefinition:
apiVersion: v1
kind: Namespace
metadata:
name: argo-example
recreateOption: None
- complianceType: musthave
objectDefinition:
apiVersion: v1
kind: Namespace
metadata:
name: argo-example-2
recreateOption: None
pruneObjectBehavior: None
remediationAction: enforce
severity: low
status:
compliancyDetails:
- Compliant: NonCompliant
Validity: {}
conditions:
- lastTransitionTime: '2024-07-29T16:34:29Z'
message: 'namespaces [argo-example] not found'
reason: K8s does not have a `must have` object
status: 'True'
type: violation
- Compliant: NonCompliant
Validity: {}
conditions:
- lastTransitionTime: '2024-07-29T16:39:00Z'
message: 'namespaces [argo-example-2] not found'
reason: K8s does not have a `must have` object
status: 'True'
type: violation
compliant: NonCompliant
lastEvaluated: '2024-07-29T16:39:18Z'
lastEvaluatedGeneration: 2
relatedObjects:
- compliant: NonCompliant
object:
apiVersion: v1
kind: Namespace
metadata:
name: argo-example
reason: Resource not found but should exist
- compliant: NonCompliant
object:
apiVersion: v1
kind: Namespace
metadata:
name: argo-example-2
reason: Resource not found but should exist