Your IP : 216.73.217.13


Current Path : /lib/python3/dist-packages/sos/report/plugins/__pycache__/
Upload File :
Current File : //lib/python3/dist-packages/sos/report/plugins/__pycache__/collectd.cpython-38.pyc

U

���b��@s.ddlZddlmZmZGdd�dee�ZdS)�N)�Plugin�IndependentPluginc@s0eZdZdZdZdZdZdZdd�Zdd	�Z	d
S)�CollectdzCollectd config collector�collectd)�servicesZ	webserver)r)�)/var/log/containers/collectd/collectd.logz/var/log/collectd/collectd.logc
Cs�|�dddddg�t�d�}zJt|�d�d��0}|D]$}|�|�r6|�d|��d	�q6W5QRXWn0tk
r�}z|�	d
|�W5d}~XYnXdS)N�/etc/collectd.conf�/etc/collectd.d/*.confrz@/var/lib/config-data/puppet-generated/collectd/etc/collectd.confzD/var/lib/config-data/puppet-generated/collectd/etc/collectd.d/*.confz
^LoadPlugin.*�rzActive Plugin found: %s���z%could not open /etc/collectd.conf: %s)
Z
add_copy_spec�re�compile�openZ	path_join�matchZ	add_alert�split�IOErrorZ	_log_warn)�self�p�f�line�e�r�=/usr/lib/python3/dist-packages/sos/report/plugins/collectd.py�setups"�	


�zCollectd.setupcCs:ddddg}dd�|�}|�d|d�|�d	|d�dS)
NZPasswordZUserz[<]*URLZAddressz((?m)^[#]*\s*(%s)\s* \s*)(.*)�|r	z
\1"*********"r)�joinZdo_path_regex_subZdo_file_sub)rZprotect_keysZregexprrr�postproc/s��zCollectd.postprocN)
�__name__�
__module__�__qualname__Z
short_descZplugin_nameZprofilesZpackages�filesrrrrrrrsr)rZsos.report.pluginsrrrrrrr�<module>
s