HEX
Server: Apache/2.4.58 (Ubuntu)
System: Linux ip-172-26-0-120 6.17.0-1009-aws #9~24.04.2-Ubuntu SMP Fri Mar 6 23:50:29 UTC 2026 x86_64
User: ubuntu (1000)
PHP: 8.3.6
Disabled: NONE
Upload Files
File: //usr/lib/python3/dist-packages/sos/policies/distros/__pycache__/cos.cpython-312.pyc
�

O6uf���<�ddlmZmZddlmZd�ZGd�de�Zy)�)�	CosPlugin�IndependentPlugin)�LinuxPolicyc�f�|j�xs|j�jd�S)aHTest whether line is empty of contains a comment.

        Test whether the ``line`` argument is either blank, or a
        whole-line comment.

        :param line: the line of text to be checked.
        :returns: ``True`` if the line is blank or a comment,
                  and ``False`` otherwise.
        :rtype: bool
    �#)�strip�lstrip�
startswith)�lines �:/usr/lib/python3/dist-packages/sos/policies/distros/cos.py�_blank_or_commentr
s)���z�z�|��<�t�{�{�}�7�7��<�<�c�P��eZdZdZdZdgZeegZdZ			d�fd�	Z
edd��Z�xZ
S)	�	CosPolicyzContainer-Optimized OSzGoogle Cloud Platform)zDistribution Websitez0https://cloud.google.com/container-optimized-os/z</usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbinc�`��t�|�||||��|xjtgz
c_y)N)�sysroot�init�
probe_runtime�remote_exec)�super�__init__�valid_subclassesr)�selfrrrr�	__class__s     �rrzCosPolicy.__init__'s4���
����t�'4�%0�	�	2�	
���)��,�rc���|r|j|vS	tdd�5}td�|D��}|ddk(cddd�S#1swYyxYw#ttf$rYywxYw)Nz/etc/os-release�rc3�pK�|].}t|�s!|j�jd����0y�w)�=N)r
r�split)�.0rs  r�	<genexpr>z"CosPolicy.check.<locals>.<genexpr>5s2����"B�d�):�4�)@�#'�*�*�,�"4�"4�S�"9�"B�s�46�ID�cosF)�distro�open�dict�IOError�KeyError)�cls�remote�fp�
os_releases    r�checkzCosPolicy.check.sy����:�:��'�'�	��'��-�
1��!�"B�b�"B�B�
�!�$�'�5�0�
1�
1�
1����"�	��	�s-�A�A�	A�A�A�A�A �A )NNTN)�)�__name__�
__module__�__qualname__r$�vendor�vendor_urlsrrr�PATHr�classmethodr-�
__classcell__)rs@rrrsK���
%�F�
$�F�	=��K�"�#4�5��I�D�>B�!�-��
��
rrN)�sos.report.pluginsrr�sos.policies.distrosrr
r�rr�<module>r:s��<�,�=���r