
                         d   S r SSKJr  SSKJr  SSKJr  SSKJr  SSSS.r	\R                  \R                  " \R                  R                  5       " S	 S
\R                  5      5       5       r\R                  \R                  " \R                  R                   5       " S S\5      5       5       rg)z Command for creating multi-MIGs.    )base_classes)utils)basez!Create a Compute Engine multi-MIGz<        *{command}* creates a Compute Engine multi-MIG.
    az        Running:

              $ {command} example-multimig --workload-policy=example-policy

      will create a multi-MIG called 'example-multimig'
      with a workload policy called 'example-policy' in the region and project which were set by `gcloud config set`.

      You can provide full path to multi-MIG name to override the region and
      project or use `--region` and `--project` flags.

      Example:

              $ {command} projects/example-project/regions/us-central1/multiMigs/example-multimig --workload-policy=example-policy --description="Multi-MIG with workload policy"

      will create a multi-MIG called 'example-multimig'
      in the region `us-central1` and project 'example-project' with a
      workload policy called 'projects/example-project/regions/us-central1/resourcePolicies/example-policy' and a description of 'Multi-MIG with workload policy'.
    )briefDESCRIPTIONEXAMPLESc                   2    \ rS rSrSr\r\S 5       rS r	Sr
g)Create3   Create a multi-MIG.c                     [         R                  " U [        R                  R                  R
                  R                  5       5        U R                  SSS9  U R                  SSS9  g )N--descriptionSets description to multi-MIG.help--workload-policyz*Specifies a workload policy for multi-MIG.r   AddMultiMigNameArgToParserr   ReleaseTrackALPHAnameloweradd_argument)parsers    (lib/surface/compute/multi_migs/create.pyArgsCreate.Args:   sf    	$$!!'',,224 -   9      c                    [         R                  " U R                  5       5      nUR                  nUR                  nUR
                  R                  R                  5       nUR                  R                  UR                  5       UR                  UR                  [        R                  " XUR                  U5      S9n[        R                   " X6U5      $ )zCreates a multi-MIG.

Args:
  args: the argparse arguments that this command was invoked with.

Returns:
  List containing one resource.
)r   descriptionregionresourcePolicies)r   ComputeApiHolderr   client	resourcesCONCEPTS	multi_migParsemessagesMultiMigNamer    r!   r   MakeResourcePolicy	api_utilsInsert)selfargsholderr$   r%   multi_mig_refr'   s          r   Run
Create.RunH   s     **4+<+<+>?F]]F  IMM++113M((!$$##11V__m
	 ) I F}==r    N)__name__
__module____qualname____firstlineno____doc__DETAILED_HELPdetailed_helpstaticmethodr   r3   __static_attributes__r5   r   r   r
   r
   3   s#     - >r   r
   c                   (    \ rS rSrSr\S 5       rSrg)CreateAlpha`   r   c                     [         R                  " U[        R                  R                  R
                  R                  5       5        UR                  SSS9  UR                  SSS9  g )Nr   r   r   r   zLTaking the resource policy ID and specifies a workload policy for multi-MIG.r   )clsr   s     r   r   CreateAlpha.Argse   sh    	$$!!'',,224 -     r   r5   N)r6   r7   r8   r9   r:   classmethodr   r>   r5   r   r   r@   r@   `   s      r   r@   N)r:   googlecloudsdk.api_lib.computer   )googlecloudsdk.api_lib.compute.multi_migsr   r-   googlecloudsdk.callioper   -googlecloudsdk.command_lib.compute.multi_migsr;   DefaultUniverseOnlyReleaseTracksr   BETACreateCommandr
   r   r@   r5   r   r   <module>rN      s    ' 8 H ( ? 16 D%%**+(>T (> , (>V D%%++,&  - r   