관리-도구
편집 파일: post_modify_domain.cpython-311.pyc
� \�Dg� � � � d Z ddlZddlmZ ddlmZ edk �r� e� � ej e �� � Ze� d�� � Z e � d d �� � Ze� dd dd�� � e� dddd�� � e � dd�� � Ze� dd dd�� � e� dddd�� � e� dddd�� � e� ddddd�� � e � dd �� � Ze� dd dd�� � e� dddd�� � e� � � Z e� � Zej d k r"e� ej ej � � dS ej dk r/e� ej ej ej ej �!� � dS ej dk r"e� ej ej � � dS e�dS )"z� Domain POST modification hook. This script must be called AFTER different domain-related changes in control panel. See --help and docs for detailed description of actions and parameters. � N)�ModifyDomainHook)�setup_logger_and_sentry�__main__)�description�command)�dest�createzH[NOT FOR VENDORS PANELS INTEGRATION] Call when domain record is created.)�helpz --usernamez-uTzUser that owns domain.)�requiredr z--domainz-dsz"Domain name e.g.: `userdomain.com`�modifyzhCall when domain record is updated (e.g all sites that have worked on old domain now work on a new one).z1Domain name before rename, e.g.: `userdomain.com`z--new-domainz-dtz0Domain name after rename, e.g.: `userdomain2.eu`z--include-subdomainsF� store_truez�If set, we will also process all domains that end with domain name (subdomains). E.g. when renaming olddomain.com -> newdomain.eu we will also rename sub.olddomain.com to sub.newdomain.eu)r �default�actionr �deletezG[NOT FOR INTEGRATED CONTROL PANELS] Call when domain record is deleted.)�include_subdomains)�__doc__�argparse�clcommon.public_hooks.libr �clcommon.public_hooksr �__name__�ArgumentParser�parser�add_subparsers� subparsers� add_parser� create_domain�add_argument� modify_domain� parse_args�args�hookr �post_create_domain�username�domain�post_modify_domain� new_domainr �post_delete_domain�NotImplementedError� � ��/builddir/build/BUILD/imunify360-venv-2.4.0/opt/imunify360/venv/lib/python3.11/site-packages/clcommon/public_hooks/bin/post_modify_domain.py�<module>r, s� ��� � ���� 6� 6� 6� 6� 6� 6� 9� 9� 9� 9� 9� 9� �z�������� $�X� $�� 9� 9� 9�F��&�&�I�&�6�6�J��)�)��a� *� c� c�M����|�T�D�G_��`�`�`����z�5�4�$H� � J� J� J� �)�)�� 1� *� 2� 2�M� ���|�T�D�G_��`�`�`����z�5�4�$W� � Y� Y� Y����~�u�t�$V� � X� X� X� ������l�I� � J� J� J� �)�)��`� *� b� b�M����|�T�D�G_��`�`�`����z�5�4�$W� � Y� Y� Y� �����D�����D��|�x�������M�4�;� (� (� (� (� (� ��� !� !�����M�4�;���#�6� � 8� 8� 8� 8� 8� ��� !� !����� �t�{�;�;�;�;�;�!�!�a �r*