Skip to content

Instantly share code, notes, and snippets.

View radikaled's full-sized avatar

radikaled

  • Issaquah, WA
  • 08:30 (UTC -07:00)
View GitHub Profile
@radikaled
radikaled / policy-acs-operator-clusters.yaml
Last active September 24, 2021 04:44
policy-advanced-managed-cluster-security (dynamic centralEndpoint and clusterName)
# This policy deploys the Red Hat Advanced Cluster Security Secure Cluster
# Services to all OpenShift managed clusters. Note that it is set to
# enforce by default and it requires RHACM 2.3 template support.
#
# Prior to applying this policy you must visit
# https://github.com/open-cluster-management/advanced-cluster-security
# and follow the instructions there to deploy prerequisite bundles
# needed by the Secure Cluster Services for communicating with the
# Central server.
#
for i in `oc get complianceremediation -n openshift-compliance -o custom-columns=NAME:.metadata.name -l compliance.openshift.io/scan-name=rhcos4-moderate-worker | tail -n +2`
do
oc patch complianceremediation ${i} -n openshift-compliance -p '{"spec":{"apply":true}}' --type=merge
done