
    F	                     b    S r SSKJr  SSKJr  SSKJr  SSKJr   " S S\R                  5      r	g)	z/Authenticate clusters using the Anthos client..    )base)anthoscli_backend)flags)
kube_flagsc                   6    \ rS rSrSrSS0r\S 5       rS rSr	g)	CreateLoginConfig   zGenerates a login configuration file.

Generates the file containing configuration information developers
will use to authenticate to an AWS Anthos cluster.
EXAMPLESaq  
      To generate the default login config file (kubectl-anthos-config.yaml) using
      the kubeconfig file 'my-kube-config.yaml':

        $ {command} --kubeconfig 'my-kube-config.yaml'

      To generate a config named 'myconfg.yaml' the --kubeconfig file 'my-kube-config.yaml':

        $ {command} --kubeconfig 'my-kube-config.yaml' --output 'myconfg.yaml'
      c                     [         R                  " SSS9R                  U 5        [        R                  " 5       R                  U 5        [        R
                  " 5       R                  U 5        g )NzXSpecifies the input kubeconfig file to access user cluster for login configuration data.T)required)r   GetKubeConfigFlagAddToParserr   GetConfigOutputFileFlagGetMergeFromFlag)parsers    )lib/surface/anthos/create_login_config.pyArgsCreateLoginConfig.Args+   sT       "= +/0 1<F0C	!!#//7	((0    c           	          [         R                  " 5       nU" SUR                  UR                  UR                  UR
                  [         R                  " 5       S9n[         R                  " U5      $ )Nzcreate-login-config)commandkube_configoutput_file
merge_fromshow_exec_errorenv)r   AnthosAuthWrapper
kubeconfigoutputr   r   GetEnvArgsForCommandLoginResponseHandler)selfargscommand_executorresponses       r   RunCreateLoginConfig.Run4   s[    (::<%OOKK??,,2246H 11(;;r    N)
__name__
__module____qualname____firstlineno____doc__detailed_helpstaticmethodr   r&   __static_attributes__r(   r   r   r   r      s1      	
- 1 1	<r   r   N)
r-   googlecloudsdk.callioper   !googlecloudsdk.command_lib.anthosr   r   (googlecloudsdk.command_lib.anthos.commonr   BinaryBackedCommandr   r(   r   r   <module>r5      s(    6 ( ? 3 ?&<00 &<r   