附录 C. redaction 配置 YAML 文件的选项
从 RHEL RHEL 6.10, 7.9, 8.3 和更高的版本开始,Insights 客户端使用 YAML 文件来配置 redaction。在早期版本中,remove.conf
文件控制掩盖操作。
C.1. redaction 配置 YAML 文件的选项
从 RHEL RHEL 6.10, 7.9, 8.3 和更高的版本开始,Insights 客户端使用 YAML 文件来配置 redaction。在早期版本中,remove.conf
文件控制掩盖操作。
内容 | 描述 |
---|---|
# file-redaction.yaml --- | 包含文件名的可选注释。 |
# Exclude the entire output of commands # Specify the full command path or the symbolic name in .cache.json commands: - /bin/rpm -qa - /bin/ls - ethtool_i |
在 |
# Exclude the entire output of files # Specify the full filename path or the symbolic name in .cache.json files: - /etc/audit/auditd.conf - cluster_conf | 对于指定的文件,文件名和文件内容不包括在归档文件中。
在 |
内容 | 描述 |
---|---|
# file-content-redaction.yaml --- | 包含文件名的可选注释。 |
# Pattern redaction per matching line # Lines that match a pattern are excluded from files and command output. # Patterns are processed in the order that they are listed. # Example patterns: - "a_string_1" - "a_string_2" |
当模式与包含 |
# # Regular expression pattern redaction per line # Patterns with regular expressions (regex) are wrapped with "regex:" # Example patterns: regex: - "abc.*def" - "localhost[[:digit:]]" # |
正则表达式被打包为 |
# Lines matching these regular expressions are excluded # from output. patterns: regex: - "*\.conf" - "^include" |
在本例中,如果任何字符串包含 |
# Replace keywords in files and command output with generic identifiers by the Python soscleaner module keywords: - "1.1.1.1" - "My Name" - "a_name" |
例如,字符串
您在 |