- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 27 for ParseIPSloppy (0.31 sec)
-
pkg/proxy/ipvs/util/ipvs_test.go
Address: netutils.ParseIPSloppy("1.2.3.4"), Port: 3080, }, rsB: &RealServer{ Address: netutils.ParseIPSloppy("1.2.3.4"), Port: 3080, }, equal: true, reason: "All fields equal", }, { rsA: &RealServer{ Address: netutils.ParseIPSloppy("2012::beef"), Port: 3080, }, rsB: &RealServer{ Address: netutils.ParseIPSloppy("2012::beef"), Port: 3080,
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Dec 19 01:20:51 UTC 2023 - 8K bytes - Viewed (0) -
pkg/registry/core/service/ipallocator/storage/storage_test.go
defer destroyFunc() if err := storage.Allocate(netutils.ParseIPSloppy("192.168.1.2")); !strings.Contains(err.Error(), "cannot allocate resources of type serviceipallocations at this time") { t.Fatal(err) } } func TestErrors(t *testing.T) { _, storage, _, _, destroyFunc := newStorage(t) defer destroyFunc() err := storage.Allocate(netutils.ParseIPSloppy("192.168.0.0")) if _, ok := err.(*ipallocator.ErrNotInRange); !ok {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Thu Aug 24 09:23:05 UTC 2023 - 5.9K bytes - Viewed (0) -
pkg/proxy/ipvs/util/testing/fake_test.go
vs := &utilipvs.VirtualServer{ Address: netutils.ParseIPSloppy("10.20.30.40"), Port: uint16(80), Protocol: string("TCP"), } rss := []*utilipvs.RealServer{ {Address: netutils.ParseIPSloppy("172.16.2.1"), Port: 8080, Weight: 1}, {Address: netutils.ParseIPSloppy("172.16.2.2"), Port: 8080, Weight: 2}, {Address: netutils.ParseIPSloppy("172.16.2.3"), Port: 8080, Weight: 3}, }
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Dec 19 01:20:51 UTC 2023 - 5.6K bytes - Viewed (0) -
pkg/util/node/node_test.go
}, expectIPs: []net.IP{netutils.ParseIPSloppy("1.2.3.4")}, }, { name: "IPv4-only, external-first", addresses: []v1.NodeAddress{ {Type: v1.NodeExternalIP, Address: "4.3.2.1"}, {Type: v1.NodeExternalIP, Address: "4.3.2.2"}, {Type: v1.NodeInternalIP, Address: "1.2.3.4"}, }, expectIPs: []net.IP{netutils.ParseIPSloppy("1.2.3.4")}, }, { name: "IPv4-only, no internal",
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri Jan 27 23:24:38 UTC 2023 - 7.1K bytes - Viewed (0) -
pkg/kubelet/certificate/kubelet_test.go
{Type: v1.NodeInternalIP, Address: "3.3.3.3"}, }, wantDNSNames: []string{"hostname-1", "hostname-2", "hostname-3"}, wantIPs: []net.IP{netutils.ParseIPSloppy("1.1.1.1"), netutils.ParseIPSloppy("2.2.2.2"), netutils.ParseIPSloppy("3.3.3.3")}, }, { name: "handle IP and DNS hostnames", addresses: []v1.NodeAddress{ {Type: v1.NodeHostName, Address: "hostname"},
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Thu Jun 06 03:07:40 UTC 2024 - 7.4K bytes - Viewed (0) -
pkg/proxy/util/endpoints.go
func IPPart(s string) string { if ip := netutils.ParseIPSloppy(s); ip != nil { // IP address without port return s } // Must be IP:port host, _, err := net.SplitHostPort(s) if err != nil { klog.ErrorS(err, "Failed to parse host-port", "input", s) return "" } // Check if host string is a valid IP address ip := netutils.ParseIPSloppy(host) if ip == nil {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Mon May 20 11:57:43 UTC 2024 - 1.3K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/server/config_selfclient_test.go
} if port != "443" { t.Fatalf("expected 443 as port, got %q", port) } host, port, err = LoopbackHostPort("0.0.0.0:443") if err != nil { t.Fatalf("unexpected error: %v", err) } if ip := netutils.ParseIPSloppy(host); ip == nil || !ip.IsLoopback() { t.Fatalf("expected host to be loopback, got %q", host) } if port != "443" { t.Fatalf("expected 443 as port, got %q", port) } }
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri Aug 20 08:42:09 UTC 2021 - 2.7K bytes - Viewed (0) -
pkg/kubeapiserver/options/serving.go
// "normal" API servers running on the platform func NewSecureServingOptions() *genericoptions.SecureServingOptionsWithLoopback { o := genericoptions.SecureServingOptions{ BindAddress: netutils.ParseIPSloppy("0.0.0.0"), BindPort: 6443, Required: true, ServerCert: genericoptions.GeneratableKeyCert{ PairName: "apiserver", CertDirectory: "/var/run/kubernetes", }, } return o.WithLoopback()
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri Aug 20 08:42:09 UTC 2021 - 1.3K bytes - Viewed (0) -
pkg/kubeapiserver/options/options.go
var DefaultServiceNodePortRange = utilnet.PortRange{Base: 30000, Size: 2768} // DefaultServiceIPCIDR is a CIDR notation of IP range from which to allocate service cluster IPs var DefaultServiceIPCIDR = net.IPNet{IP: netutils.ParseIPSloppy("10.0.0.0"), Mask: net.CIDRMask(24, 32)} // DefaultEtcdPathPrefix is the default key prefix of etcd for API Server
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri Aug 20 08:42:09 UTC 2021 - 1.1K bytes - Viewed (0) -
pkg/util/flag/flags.go
// Attempt to parse into IP first. if netutils.ParseIPSloppy(s) != nil { *v.Val = s return nil } // Can not parse into IP, now assume IP:port. host, port, err := net.SplitHostPort(s) if err != nil { return fmt.Errorf("%q is not in a valid format (ip or ip:port): %v", s, err) } if netutils.ParseIPSloppy(host) == nil { return fmt.Errorf("%q is not a valid IP address", host) }
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Jul 19 03:30:46 UTC 2022 - 7.8K bytes - Viewed (0)