Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for isMCPAddr (0.36 sec)

  1. istioctl/pkg/kubeinject/google.go

    // limitations under the License.
    
    package kubeinject
    
    import (
    	"context"
    	"fmt"
    	"net/http"
    	"strings"
    
    	"golang.org/x/oauth2"
    	"golang.org/x/oauth2/google"
    )
    
    func isMCPAddr(addr string) bool {
    	// A bit inexact but should be good enough.
    	return strings.Contains(addr, ".googleapis.com/") || strings.Contains(addr, ".googleapis.com:443/")
    }
    
    Go
    - Registered: Wed May 01 22:53:12 GMT 2024
    - Last Modified: Thu Jun 15 15:02:17 GMT 2023
    - 1.2K bytes
    - Viewed (0)
  2. istioctl/pkg/multixds/google.go

    // See the License for the specific language governing permissions and
    // limitations under the License.
    
    package multixds
    
    import (
    	"fmt"
    	"net/url"
    	"strings"
    )
    
    func isMCPAddr(u *url.URL) bool {
    	return strings.HasSuffix(u.Host, ".googleapis.com") || strings.HasSuffix(u.Host, ".googleapis.com:443")
    }
    
    func parseMCPAddr(u *url.URL) (*xdsAddr, error) {
    	ret := &xdsAddr{host: u.Host}
    Go
    - Registered: Wed May 01 22:53:12 GMT 2024
    - Last Modified: Mon Jun 06 03:39:27 GMT 2022
    - 1.5K bytes
    - Viewed (1)
  3. istioctl/pkg/multixds/gather.go

    		for _, wh := range whc.Webhooks {
    			if wh.ClientConfig.URL != nil {
    				u, err := url.Parse(*wh.ClientConfig.URL)
    				if err != nil {
    					return nil, fmt.Errorf("parsing webhook URL: %w", err)
    				}
    				if isMCPAddr(u) {
    					return parseMCPAddr(u)
    				}
    				port := u.Port()
    				if port == "" {
    					port = "443" // default from Kubernetes
    				}
    				return &xdsAddr{host: net.JoinHostPort(u.Hostname(), port)}, nil
    			}
    Go
    - Registered: Wed May 01 22:53:12 GMT 2024
    - Last Modified: Fri Mar 08 08:38:19 GMT 2024
    - 13.6K bytes
    - Viewed (0)
  4. istioctl/pkg/kubeinject/kubeinject.go

    			defer func() {
    				f.Close()
    				f.WaitForStop()
    			}()
    		}
    		tlsClientConfig.ServerName = fmt.Sprintf("%s.%s.%s", cc.Service.Name, cc.Service.Namespace, "svc")
    	} else if isMCPAddr(address) {
    		var err error
    		client.Transport, err = mcpTransport(context.TODO(), client.Transport)
    		if err != nil {
    			return nil, err
    		}
    	}
    	podBytes, err := json.Marshal(pod)
    Go
    - Registered: Wed May 01 22:53:12 GMT 2024
    - Last Modified: Fri Mar 29 02:29:02 GMT 2024
    - 21.6K bytes
    - Viewed (0)
Back to top