package service
import "k8s.io/kubernetes/pkg/api/service"
Index ¶
- func ExternallyAccessible(service *api.Service) bool
- func GetLoadBalancerSourceRanges(service *api.Service) (utilnet.IPNetSet, error)
- func GetWarningsForService(service, oldService *api.Service) []string
- func IsAllowAll(ipnets utilnet.IPNetSet) bool
- func NeedsHealthCheck(service *api.Service) bool
- func RequestsOnlyLocalTraffic(service *api.Service) bool
Functions ¶
func ExternallyAccessible ¶
ExternallyAccessible checks if service is externally accessible.
func GetLoadBalancerSourceRanges ¶
GetLoadBalancerSourceRanges first try to parse and verify LoadBalancerSourceRanges field from a service. If the field is not specified, turn to parse and verify the AnnotationLoadBalancerSourceRangesKey annotation from a service, extracting the source ranges to allow, and if not present returns a default (allow-all) value.
func GetWarningsForService ¶
func IsAllowAll ¶
IsAllowAll checks whether the utilnet.IPNet allows traffic from 0.0.0.0/0
func NeedsHealthCheck ¶
NeedsHealthCheck checks if service needs health check.
func RequestsOnlyLocalTraffic ¶
RequestsOnlyLocalTraffic checks if service requests OnlyLocal traffic.
Source Files ¶
util.go warnings.go
Directories ¶
Path | Synopsis |
---|---|
pkg/api/service/testing |
- Version
- v1.33.0 (latest)
- Published
- Apr 23, 2025
- Platform
- linux/amd64
- Imports
- 7 packages
- Last checked
- 3 hours ago –
Tools for package owners.