
    	                        d Z ddlmZ ddlmZ ddlmZ ddlmZ ddlmZ ddlmZ ddl	m
Z
 dd	lmZ e
j                   e
j                  e
j                  j                          G d
 de
j"                                      Zy)z2Export Binary Authorization system policy command.    )absolute_import)division)unicode_literals)apis)system_policy)util)base)arg_parsersc                   &    e Zd ZdZed        Zd Zy)ExportSystemPolicya  Export the Binary Authorization system policy.

  For reliability reasons, the system policy is updated one region at a time.
  Because of this precaution, the system policy can differ between regions
  during an update. Use --location to view the system policy of a specific
  region.

  If --location is not specified, an arbitrary region is used. (Specifically, a
  region in the last group of regions to receive updates. Since most changes are
  additions, this will show the minimal set of system images that are allowed
  in all regions.)

  ## EXAMPLES

  To view the system policy:

      $ {command}

  To view the system policy in the region us-central1:

      $ {command} --location=us-central1
  c                 L    |j                  dt        j                  ddd       y )Nz
--locationFglobalz<The region for which to get the system policy (or "global").)choicesrequireddefaulthelp)add_argumentr
   BINAUTHZ_ENFORCER_REGIONS)clsparsers     =lib/surface/container/binauthz/policy/export_system_policy.pyArgszExportSystemPolicy.Args6   s-    
 55K  M    c                     t        j                  | j                               }t        j                  |      j                  t        j                  |j                              S )N)	r   GetApiVersionReleaseTrackr   ClientGetr   GetSystemPolicyReflocation)selfargsapi_versions      r   RunzExportSystemPolicy.RunA   sK    $$T%6%6%89K,00.0 0r   N)__name__
__module____qualname____doc__classmethodr   r$    r   r   r   r      s"    . M M0r   r   N)r(   
__future__r   r   r   )googlecloudsdk.api_lib.container.binauthzr   r   r   googlecloudsdk.callioper	   -googlecloudsdk.command_lib.container.binauthzr
   DefaultUniverseOnlyReleaseTracksr   ALPHACommandr   r*   r   r   <module>r3      sh    9 &  ' : C : ( E D%%++,&0 &0 - &0r   