You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: modules/compliance-tailored-profiles.adoc
+22-14Lines changed: 22 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,19 +14,20 @@ The `ComplianceSuite` object contains an optional `TailoringConfigMap` attribute
14
14
+
15
15
[source,terminal]
16
16
----
17
-
$ oc get rules.compliance -l compliance.openshift.io/profile-bundle=rhcos4
17
+
$ oc get rules.compliance -n openshift-compliance -l compliance.openshift.io/profile-bundle=rhcos4
18
18
----
19
19
20
20
. Browse the available variables in the same `ProfileBundle`:
21
21
+
22
22
[source,terminal]
23
23
----
24
-
$ oc get variables.compliance -l compliance.openshift.io/profile-bundle=rhcos4
24
+
$ oc get variables.compliance -n openshift-compliance -l compliance.openshift.io/profile-bundle=rhcos4
25
25
----
26
26
27
-
. Choose which rules you want to add to the `TailoredProfile`. This `TailoredProfile` example disables two rules and changes one value. Use the `rationale` value to describe why these changes were made:
27
+
. Create a tailored profile named `nist-moderate-modified`:
28
+
.. Choose which rules you want to add to the `nist-moderate-modified` tailored profile. This example extends the `rhcos4-moderate` profile by disabling two rules and changing one value. Use the `rationale` value to describe why these changes were made:
28
29
+
29
-
.Example output
30
+
.Example `new-profile-node.yaml`
30
31
[source,yaml]
31
32
----
32
33
apiVersion: compliance.openshift.io/v1alpha1
@@ -35,20 +36,18 @@ metadata:
35
36
name: nist-moderate-modified
36
37
spec:
37
38
extends: rhcos4-moderate
39
+
description: NIST moderate profile
38
40
title: My modified NIST moderate profile
39
41
disableRules:
40
-
- name: rhcos4-file-permissions-node-config
41
-
rationale: This breaks X application.
42
+
- name: rhcos4-file-permissions-var-log-messages
43
+
rationale: The file contains logs of error messages in the system
42
44
- name: rhcos4-account-disable-post-pw-expiration
43
45
rationale: No need to check this as it comes from the IdP
44
46
setValues:
45
47
- name: rhcos4-var-selinux-state
46
48
rationale: Organizational requirements
47
49
value: permissive
48
50
----
49
-
+
50
-
51
-
52
51
+
53
52
.Attributes for spec variables
54
53
[cols="1,2a",options="header"]
@@ -74,15 +73,24 @@ spec:
74
73
|`setValues`
75
74
| A list of name, rationale, and value groupings. Each name refers to a name of the value set. The rationale is human-readable text describing the set. The value is the actual setting.
76
75
|===
77
-
+
78
-
. Add the profile to the `ScanSettingsBinding` object:
0 commit comments