RsyslogConf - file /etc/rsyslog.conf
The rsyslog configuration files can include statements with two different line based formats along with snippets of ‘RainerScript’ that can span multiple lines.
See http://www.rsyslog.com/doc/master/configuration/basic_structure.html#statement-types
Due to high parsing complexity, this parser presents a simple line-based view of the file that meets the needs of the current rules.
- class insights.parsers.rsyslog_conf.RsyslogConf(*args, **kwargs)[source]
Bases:
Parser
,list
Parses /etc/rsyslog.conf content.
Skips lines that begin with hash (“#”) or are only whitespace.
- data
List of lines in the file that don’t start with ‘#’ and aren’t whitespace.
- Type:
list
Example
>>> type(rsysconf) <class 'insights.parsers.rsyslog_conf.RsyslogConf'> >>> len(rsysconf) 13 >>> rsysconf[2] 'authpriv.* /var/log/secure'