HEX
Server: Apache
System: Linux 185.122.168.184.host.secureserver.net 5.14.0-570.60.1.el9_6.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Nov 5 05:00:59 EST 2025 x86_64
User: barbeatleanalyti (1024)
PHP: 8.1.33
Disabled: NONE
Upload Files
File: //lib/python3.9/site-packages/sos/report/plugins/__pycache__/etcd.cpython-39.pyc
a

\��h��@s&ddlmZmZGdd�dee�ZdS)�)�Plugin�RedHatPluginc@s4eZdZdZdZdZdZdZdZdZ	dZ
dd	�Zd
S)�Etcda�The etcd plugin collects information from the etcd key-value store. It
    is primarily used by Kubernetes/OpenShift clusters and is often run inside
    a container within the cluster.

    Collections will default to executing within an `etcdctl` container, if one
    is present, and only execute on the host if such a container is not
    currently running. The `etcdctl` name preference is adopted from OpenShift
    Container Platform deployments.

    This plugin is written for etcd v3 and later.
    zetcd plugin�etcd)r)�	container�system�servicesZcluster)�/etc/etcd/etcd.conf)ZetcdctlrcCs�d}|jD]}|�|�r
|}q"q
|�ddi�|�ddg�|jd|dd�|jd|d	�gd
�}|jdd�|D�|d	�dS)
Nr	Z	etcd_confz/etc/etcd/caz/etc/etcd/*.keyz/var/lib/etcd/T)r�	recursivez	/etc/etcd)r)�versionzmember listz
alarm listzendpoint statuszendpoint healthcSsg|]}d|���qS)zetcdctl �)�.0�subrr�;/usr/lib/python3.9/site-packages/sos/report/plugins/etcd.py�
<listcomp>C�zEtcd.setup.<locals>.<listcomp>)�
containersZget_container_by_nameZ
add_file_tagsZadd_forbidden_pathZadd_dir_listingZ
add_copy_specZadd_cmd_output)�selfZetcd_conZconZsubcmdsrrr�setup%s*

����z
Etcd.setupN)�__name__�
__module__�__qualname__�__doc__Z
short_descZplugin_nameZpackagesZprofiles�filesrrrrrrrrsrN)Zsos.report.pluginsrrrrrrr�<module>s