File: //lib/google-cloud-sdk/lib/surface/stacks/__pycache__/deploy.cpython-312.pyc
�
��� � �� � d Z ddlmZ ddlmZ ddlmZ ddlmZ ddlmZ ddlm Z ddlm
Z
dd lmZ ej ej j � G d
� dej � � Zy)
zICommand for creating or replacing an application from YAML specification.� )�absolute_import)�division)�print_function)�unicode_literals)�base)�flags)�run_apps_operations)�
exceptionsc �6 � e Zd ZdZddd�Zed� � Zd� Zd� Zy) �Deployz;Create or replace an application from a YAML specification.z" {description}
zf To create an application from specification
$ {command} stack.yaml
)�DESCRIPTION�EXAMPLESc �X � t j |� t j |� y )N)r �
AddFileArg�AddServiceAccountArg)�cls�parsers �lib/surface/stacks/deploy.py�ArgszDeploy.Args, s � � ���V�� ���v�&� c �p � d|vrd|vrt j d� �d|v rt j d� �y )N�name� resourcesz!'name' or 'resources' is missing.z/tztabs found in manifest content.)r
�FieldMismatchError�ConfigurationError)�self�file_contents r �_ValidateAppConfigFilezDeploy._ValidateAppConfigFile1 sB � �
�\�!�k��&E��)�)�*M�N�N��|���)�)�*K�L�L� r c � � |j }| j |� | j � }t j ||� 5 }|j � |j
|� cddd� S # 1 sw Y yxY w)z'Create or Update application from YAML.N)�FILEr �ReleaseTrackr �Connect�VerifyLocation� ApplyYaml)r �argsr �
release_track�clients r �Runz
Deploy.Run7 sa � � �9�9�L�����-��%�%�'�M� � $� $�T�=� 9�V�����
�
�
�l�
+�
:� 9� 9�s �!A/�/A8N) �__name__�
__module__�__qualname__�__doc__�
detailed_help�classmethodr r r( � r r r r s5 � �C��
�
�-� �'� �'�M�
,r r N)r, �
__future__r r r r �googlecloudsdk.callioper �+googlecloudsdk.command_lib.run.integrationsr r �"googlecloudsdk.command_lib.runappsr
�
ReleaseTracksr! �ALPHA�Commandr r/ r r �<module>r7 s[ �� P� &� � %� '� (� =� K� 9� ����D�%�%�+�+�,�$,�T�\�\� $,� -�$,r