
    M                        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KJr  SS	KJr  SS
KJr  SSS.r\	R&                  " \	R(                  R*                  5       " S S\R,                  5      5       r\	R&                  " \	R(                  R0                  5       " S S\5      5       r\	R&                  " \	R(                  R4                  5       " S S\5      5       rg)zJRemoves an invoker binding from the IAM policy of a Google Cloud Function.    )absolute_import)division)unicode_literals)util)base)parser_extensions)flags)command)iam_utila        Removes the invoker role IAM policy binding that allows the specified
      member to invoke the specified function.

      For Cloud Functions (1st gen), this removes the Cloud Functions Invoker
      binding from the IAM policy of the specified function.

      For Cloud Functions (2nd gen), this removes the Cloud Run Invoker binding
      from the IAM policy of the specified function's underlying Cloud Run
      service.
      z          To remove the invoker role policy binding for `FUNCTION-1` for member
          `MEMBER-1` run:

            $ {command} FUNCTION-1 --member=MEMBER-1
          )DESCRIPTIONEXAMPLESc                   p    \ rS rSrSr\r\S 5       rS\	R                  4S jrS\	R                  4S jrSrg)	RemoveInvokerPolicyBinding3   Removes an invoker binding from the IAM policy of a Google Cloud Function.

This command applies to Cloud Functions 2nd gen only.
c                     [         R                  " U S5        [         R                  " U SSS9  [        R                  " U SS5        g)z!Registers flags for this command.z"to remove the invoker binding fromT)hiddenzto remove from the IAM policyFN)r	   AddFunctionResourceArgAddGen2Flagr   AddMemberFlag)parsers    6lib/surface/functions/remove_invoker_policy_binding.pyArgsRemoveInvokerPolicyBinding.Args<   s;     
  )MN	fB4P6#BEJ    argsc                     [         R                  " UR                  R                  R	                  5       R                  5       UR                  SS9$ )Nzroles/cloudfunctions.invoker)memberrole)api_util_v1%RemoveFunctionIamPolicyBindingIfFoundCONCEPTSnameParseRelativeNamer   selfr   s     r   _RunV1!RemoveInvokerPolicyBinding._RunV1C   s>    <<  "//1{{+ r   c                 J    [         R                  " XR                  5       5      $ )N)
command_v2RunReleaseTrackr&   s     r   _RunV2!RemoveInvokerPolicyBinding._RunV2J   s    >>$ 1 1 344r    N)__name__
__module____qualname____firstlineno____doc___DETAILED_HELPdetailed_helpstaticmethodr   r   	Namespacer(   r.   __static_attributes__r0   r   r   r   r   3   sH    
 !-K K*44 5*44 5r   r   c                       \ rS rSrSrSrg)RemoveInvokerPolicyBindingBetaN   r   r0   Nr1   r2   r3   r4   r5   r:   r0   r   r   r<   r<   N       r   r<   c                       \ rS rSrSrSrg)RemoveInvokerPolicyBindingAlphaV   r   r0   Nr>   r0   r   r   rA   rA   V   r?   r   rA   N)r5   
__future__r   r   r   #googlecloudsdk.api_lib.functions.v1r   r    googlecloudsdk.callioper   r   $googlecloudsdk.command_lib.functionsr	   Egooglecloudsdk.command_lib.functions.v2.remove_invoker_policy_bindingr
   r+   googlecloudsdk.command_lib.iamr   r6   ReleaseTracksr-   GAFunctionResourceCommandr   BETAr<   ALPHArA   r0   r   r   <module>rN      s    Q &  ' C ( 5 6 5 g 3

* D%%(()5!=!= 5 *54 D%%**+%?  , D%%++,&D  -r   