Skip to content

Commit

Permalink
Fixing rule checks for CMP-3034
Browse files Browse the repository at this point in the history
  • Loading branch information
rutvik23 committed Dec 9, 2024
1 parent 41429f5 commit c0c5b35
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,20 +20,20 @@ ocil_clause: 'the security profiles operator is not installed'

ocil: |-
To check if the Security Profiles Operator is installed, run the following command:
<pre>oc get sub -nopenshift-security-profiles security-profiles-operator-sub -ojsonpath='{.status.installedCSV}'</pre>
<pre>oc get sub -nopenshift-security-profiles security-profiles-operator -ojsonpath='{.status.installedCSV}'</pre>
the output should return the version of the CSV that represents the installed operator.
severity: medium

warnings:
- general: |-
{{{ openshift_cluster_setting("/apis/operators.coreos.com/v1alpha1/namespaces/openshift-security-profiles/subscriptions/security-profiles-operator-sub") | indent(4) }}}
{{{ openshift_cluster_setting("/apis/operators.coreos.com/v1alpha1/namespaces/openshift-security-profiles/subscriptions/security-profiles-operator") | indent(4) }}}
template:
name: yamlfile_value
vars:
ocp_data: 'true'
filepath: /apis/operators.coreos.com/v1alpha1/namespaces/openshift-security-profiles/subscriptions/security-profiles-operator-sub
filepath: /apis/operators.coreos.com/v1alpha1/namespaces/openshift-security-profiles/subscriptions/security-profiles-operator
yamlpath: .status.installedCSV
values:
- value: security-profiles-operator\.v.*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,6 @@ oc wait -n openshift-security-profiles --for=condition=Available --timeout=300s
deployment/security-profiles-operator

echo "waiting the subscription to have .status.installedCSV"
while [ -z "$(oc get subscription security-profiles-operator-sub -nopenshift-security-profiles -o jsonpath='{.status.installedCSV}')" ]; do
while [ -z "$(oc get subscription security-profiles-operator -nopenshift-security-profiles -o jsonpath='{.status.installedCSV}')" ]; do
sleep 3
done

0 comments on commit c0c5b35

Please sign in to comment.