
    Q	                         S r SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  SSK	J
r
  SSK	Jr   " S S	\R                  \R                  \
R                  5      rg
)z6The command to suspend the Policy Controller webhooks.    )absolute_import)division)unicode_literals)base)command)flagsc                   <    \ rS rSrSrSrSr\S 5       rS r	S r
Srg)	Suspend   a  Suspend Policy Controller Feature.

Suspends the Policy Controller. This will disable all kubernetes webhooks on
the configured cluster, thereby removing admission and mutation functionality.
Audit functionality will remain in place.

## EXAMPLES

To suspend Policy Controller, run:

  $ {command}

To re-enable Policy Controller webhooks, use the `enable` command:

  $ {parent_command} enable
policycontrollerc                 R    [         R                  " US5      nUR                  5         g )Nsuspend)r   	PocoFlagsadd_memberships)clsparser	cmd_flagss      7lib/surface/container/fleet/policycontroller/suspend.pyArgsSuspend.Args0   s    	2I    c                     U R                  U5      nUR                  5        VVs0 s H  u  p4X0R                  U5      _M     nnnU R                  U5      $ s  snnf )N)
path_specsitemsr   update_specs)selfargsspecspathspecupdated_specss         r   RunSuspend.Run5   sX    OOD!E38;;=3@ZTll4  =   ]++s   Ac                     U R                   R                  R                  R                  UR                  R
                  l        U$ )zSets the membership spec to SUSPENDED.

Args:
  spec: The spec to be suspended.

Returns:
  Updated spec, based on message api version.
)messagesPolicyControllerHubConfigInstallSpecValueValuesEnumINSTALL_SPEC_SUSPENDEDr   policyControllerHubConfiginstallSpec)r   r    s     r   r   Suspend.suspend<   s8     	//JJaa 	33? Kr    N)__name__
__module____qualname____firstlineno____doc__feature_namemf_nameclassmethodr   r"   r   __static_attributes__r,   r   r   r
   r
      s/    " $,'   ,r   r
   N)r1   
__future__r   r   r   3googlecloudsdk.command_lib.container.fleet.featuresr   =googlecloudsdk.command_lib.container.fleet.membershipfeaturesmf_base;googlecloudsdk.command_lib.container.fleet.policycontrollerr   r   UpdateCommandPocoCommandr
   r,   r   r   <module>r=      sA    = &  ' D Y O M-d  '"7"79L9L -r   