Beispiel #1
0
    def Args(cls, parser):
        parser.display_info.AddFormat(flags.DEFAULT_LIST_FORMAT)
        certs = parser.add_mutually_exclusive_group(required=True)
        cls.SSL_CERTIFICATE_ARG = (
            ssl_certificates_flags.SslCertificateArgumentForOtherResource(
                'target HTTPS proxy', required=False))
        cls.SSL_CERTIFICATE_ARG.AddArgument(parser, mutex_group=certs)
        cls.SSL_CERTIFICATES_ARG = (
            ssl_certificates_flags.SslCertificatesArgumentForOtherResource(
                'target HTTPS proxy', required=False))
        cls.SSL_CERTIFICATES_ARG.AddArgument(parser,
                                             mutex_group=certs,
                                             cust_metavar='SSL_CERTIFICATE')

        cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument()
        cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser, operation_type='create')
        cls.URL_MAP_ARG = url_map_flags.UrlMapArgumentForTargetProxy(
            proxy_type='HTTPS')
        cls.URL_MAP_ARG.AddArgument(parser)

        parser.add_argument(
            '--description',
            help='An optional, textual description for the target HTTPS proxy.'
        )
        parser.display_info.AddCacheUpdater(flags.TargetHttpsProxiesCompleter)
Beispiel #2
0
    def Args(cls, parser):
        cls.SSL_CERTIFICATES_ARG = (
            ssl_certificates_flags.SslCertificatesArgumentForOtherResource(
                'target HTTPS proxy',
                required=False,
                include_alpha=cls._include_l7_internal_load_balancing))
        cls.SSL_CERTIFICATES_ARG.AddArgument(parser,
                                             cust_metavar='SSL_CERTIFICATE')

        cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument(
            include_l7_internal_load_balancing=cls.
            _include_l7_internal_load_balancing)
        cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser, operation_type='update')

        cls.URL_MAP_ARG = url_map_flags.UrlMapArgumentForTargetProxy(
            required=False,
            proxy_type='HTTPS',
            include_l7_internal_load_balancing=cls.
            _include_l7_internal_load_balancing)
        cls.URL_MAP_ARG.AddArgument(parser)

        group = parser.add_mutually_exclusive_group()
        cls.SSL_POLICY_ARG = (
            ssl_policies_flags.GetSslPolicyArgumentForOtherResource(
                'HTTPS', required=False))
        cls.SSL_POLICY_ARG.AddArgument(group)
        ssl_policies_flags.GetClearSslPolicyArgumentForOtherResource(
            'HTTPS', required=False).AddToParser(group)

        target_proxies_utils.AddQuicOverrideUpdateArgs(parser)
Beispiel #3
0
  def Args(cls, parser):
    ssl_certificates_required = not cls._traffic_director_security

    cls.SSL_CERTIFICATES_ARG = (
        ssl_certificates_flags.SslCertificatesArgumentForOtherResource(
            'target HTTPS proxy',
            required=ssl_certificates_required,
            include_l7_internal_load_balancing=cls
            ._include_l7_internal_load_balancing))
    cls.SSL_CERTIFICATES_ARG.AddArgument(parser, cust_metavar='SSL_CERTIFICATE')

    cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument(
        include_l7_internal_load_balancing=cls
        ._include_l7_internal_load_balancing)
    cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser, operation_type='create')

    cls.URL_MAP_ARG = url_map_flags.UrlMapArgumentForTargetProxy(
        proxy_type='HTTPS',
        include_l7_internal_load_balancing=cls
        ._include_l7_internal_load_balancing)
    cls.URL_MAP_ARG.AddArgument(parser)

    cls.SSL_POLICY_ARG = (
        ssl_policies_flags.GetSslPolicyArgumentForOtherResource(
            'HTTPS', required=False))
    cls.SSL_POLICY_ARG.AddArgument(parser)

    _Args(
        parser,
        include_l7_internal_load_balancing=cls
        ._include_l7_internal_load_balancing,
        traffic_director_security=cls._traffic_director_security)
Beispiel #4
0
    def Args(cls, parser):
        parser.display_info.AddFormat(flags.DEFAULT_LIST_FORMAT)
        cls.SSL_CERTIFICATES_ARG = (
            ssl_certificates_flags.SslCertificatesArgumentForOtherResource(
                'target HTTPS proxy'))
        cls.SSL_CERTIFICATES_ARG.AddArgument(parser,
                                             cust_metavar='SSL_CERTIFICATE')

        cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument()
        cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser, operation_type='create')

        cls.URL_MAP_ARG = url_map_flags.UrlMapArgumentForTargetProxy(
            proxy_type='HTTPS')
        cls.URL_MAP_ARG.AddArgument(parser)

        cls.SSL_POLICY_ARG = (
            ssl_policies_flags.GetSslPolicyArgumentForOtherResource(
                'HTTPS', required=False))
        cls.SSL_POLICY_ARG.AddArgument(parser)

        parser.add_argument(
            '--description',
            help='An optional, textual description for the target HTTPS proxy.'
        )
        parser.display_info.AddCacheUpdater(flags.TargetHttpsProxiesCompleter)

        target_proxies_utils.AddQuicOverrideCreateArgs(parser)
Beispiel #5
0
 def Args(cls, parser):
     cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument(
         plural=True,
         include_l7_internal_load_balancing=cls.
         _include_l7_internal_load_balancing)
     cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser, operation_type='delete')
     if cls._include_l7_internal_load_balancing:
         parser.display_info.AddCacheUpdater(
             flags.TargetHttpsProxiesCompleterAlpha)
Beispiel #6
0
 def Args(cls, parser):
     cls.SSL_CERTIFICATE_ARG = (
         ssl_certificates_flags.SslCertificateArgumentForTargetHttpsProxies(
             required=False))
     cls.SSL_CERTIFICATE_ARG.AddArgument(parser)
     cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument()
     cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser)
     cls.URL_MAP_ARG = url_maps_flags.UrlMapArgumentForTargetHttpsProxy(
         required=False)
     cls.URL_MAP_ARG.AddArgument(parser)
Beispiel #7
0
 def Args(cls, parser):
   cls.SSL_CERTIFICATE_ARG = (
       ssl_certificate_flags.SslCertificateArgumentForOtherResource(
           'target HTTPS proxy', required=False))
   cls.SSL_CERTIFICATE_ARG.AddArgument(parser)
   cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument()
   cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser)
   cls.URL_MAP_ARG = url_map_flags.UrlMapArgumentForTargetProxy(
       required=False, proxy_type='HTTPS')
   cls.URL_MAP_ARG.AddArgument(parser)
Beispiel #8
0
    def Args(cls, parser):
        cls.SSL_CERTIFICATES_ARG = (
            ssl_certificates_flags.SslCertificatesArgumentForOtherResource(
                'target HTTPS proxy',
                required=False,
                include_l7_internal_load_balancing=cls.
                _include_l7_internal_load_balancing))
        if not cls._certificate_map:
            cls.SSL_CERTIFICATES_ARG.AddArgument(
                parser, cust_metavar='SSL_CERTIFICATE')

        cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument(
            include_l7_internal_load_balancing=cls.
            _include_l7_internal_load_balancing)
        cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser, operation_type='update')

        cls.URL_MAP_ARG = url_map_flags.UrlMapArgumentForTargetProxy(
            required=False,
            proxy_type='HTTPS',
            include_l7_internal_load_balancing=cls.
            _include_l7_internal_load_balancing)
        cls.URL_MAP_ARG.AddArgument(parser)

        if cls._certificate_map:
            group = parser.add_mutually_exclusive_group()
            cert_group = group.add_argument_group()
            cls.SSL_CERTIFICATES_ARG.AddArgument(
                cert_group, cust_metavar='SSL_CERTIFICATE')
            map_group = group.add_mutually_exclusive_group()
            resource_args.AddCertificateMapResourceArg(map_group,
                                                       'to attach',
                                                       name='certificate-map',
                                                       positional=False,
                                                       required=False,
                                                       with_location=False)
            resource_args.GetClearCertificateMapArgumentForOtherResource(
                'HTTPS proxy').AddToParser(map_group)

        if cls._regional_ssl_policies:
            cls.SSL_POLICY_ARG = ssl_policies_flags.GetSslPolicyMultiScopeArgumentForOtherResource(
                'HTTPS', required=False)
        else:
            cls.SSL_POLICY_ARG = ssl_policies_flags.GetSslPolicyArgumentForOtherResource(
                'HTTPS', required=False)

        group = parser.add_mutually_exclusive_group()
        ssl_policy_group = group.add_argument_group()
        cls.SSL_POLICY_ARG.AddArgument(ssl_policy_group)

        ssl_policies_flags.GetClearSslPolicyArgumentForOtherResource(
            'HTTPS', required=False).AddToParser(group)

        target_proxies_utils.AddQuicOverrideUpdateArgs(parser)
Beispiel #9
0
    def Args(cls, parser):
        cls.SSL_CERTIFICATE_ARG = (
            ssl_certificate_flags.SslCertificateArgumentForOtherResource(
                'target HTTPS proxy'))
        cls.SSL_CERTIFICATE_ARG.AddArgument(parser)
        cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument()
        cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser)
        cls.URL_MAP_ARG = url_map_flags.UrlMapArgumentForTargetHttpsProxy()
        cls.URL_MAP_ARG.AddArgument(parser)

        parser.add_argument(
            '--description',
            help='An optional, textual description for the target HTTPS proxy.'
        )
Beispiel #10
0
  def Args(cls, parser):
    parser.display_info.AddFormat(flags.DEFAULT_LIST_FORMAT)
    cls.SSL_CERTIFICATE_ARG = (
        ssl_certificate_flags.SslCertificateArgumentForOtherResource(
            'target HTTPS proxy'))
    cls.SSL_CERTIFICATE_ARG.AddArgument(parser)
    cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument()
    cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser)
    cls.URL_MAP_ARG = url_map_flags.UrlMapArgumentForTargetProxy(
        proxy_type='HTTPS')
    cls.URL_MAP_ARG.AddArgument(parser)

    parser.add_argument(
        '--description',
        help='An optional, textual description for the target HTTPS proxy.')
Beispiel #11
0
  def Args(cls, parser):
    certs = parser.add_mutually_exclusive_group()
    cls.SSL_CERTIFICATE_ARG = (
        ssl_certificates_flags.SslCertificateArgumentForOtherResource(
            'target HTTPS proxy', required=False))
    cls.SSL_CERTIFICATE_ARG.AddArgument(parser, mutex_group=certs)
    cls.SSL_CERTIFICATES_ARG = (
        ssl_certificates_flags.SslCertificatesArgumentForOtherResource(
            'target HTTPS proxy', required=False))
    cls.SSL_CERTIFICATES_ARG.AddArgument(
        parser, mutex_group=certs, cust_metavar='SSL_CERTIFICATE')

    cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument()
    cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser, operation_type='update')
    cls.URL_MAP_ARG = url_map_flags.UrlMapArgumentForTargetProxy(
        required=False, proxy_type='HTTPS')
    cls.URL_MAP_ARG.AddArgument(parser)
Beispiel #12
0
    def Args(cls, parser):
        cls.SSL_CERTIFICATES_ARG = (
            ssl_certificates_flags.SslCertificatesArgumentForOtherResource(
                'target HTTPS proxy'))
        cls.SSL_CERTIFICATES_ARG.AddArgument(parser,
                                             cust_metavar='SSL_CERTIFICATE')

        cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument()
        cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser, operation_type='create')

        cls.URL_MAP_ARG = url_map_flags.UrlMapArgumentForTargetProxy(
            proxy_type='HTTPS')
        cls.URL_MAP_ARG.AddArgument(parser)

        cls.SSL_POLICY_ARG = (
            ssl_policies_flags.GetSslPolicyArgumentForOtherResource(
                'HTTPS', required=False))
        cls.SSL_POLICY_ARG.AddArgument(parser)

        _Args(parser)

        target_proxies_utils.AddQuicOverrideCreateArgs(parser)
Beispiel #13
0
 def Args(cls, parser):
     cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument(
         plural=True, include_alpha=True)
     cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser, operation_type='delete')
     parser.display_info.AddCacheUpdater(
         flags.TargetHttpsProxiesCompleterAlpha)
Beispiel #14
0
 def Args(parser):
     Delete.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument(
         plural=True)
     Delete.TARGET_HTTPS_PROXY_ARG.AddArgument(parser,
                                               operation_type='delete')
Beispiel #15
0
 def Args(cls, parser):
     cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument(
         include_alpha=True)
     cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser,
                                            operation_type='describe')
Beispiel #16
0
 def Args(cls, parser):
     cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument(
         include_l7_internal_load_balancing=cls.
         _include_l7_internal_load_balancing)
     cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser,
                                            operation_type='describe')
Beispiel #17
0
 def Args(parser):
   Describe.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument()
   Describe.TARGET_HTTPS_PROXY_ARG.AddArgument(
       parser, operation_type='describe')
Beispiel #18
0
 def Args(cls, parser):
     cls.TARGET_HTTPS_PROXY_ARG = flags.TargetHttpsProxyArgument(
         include_l7_internal_load_balancing=True)
     cls.TARGET_HTTPS_PROXY_ARG.AddArgument(parser, operation_type='import')
     export_util.AddImportFlags(
         parser, _GetSchemaPath(cls.ReleaseTrack(), for_help=True))