kubernetesk8s.io/kubernetes/pkg/api/v1/service Index | Files

package service

import "k8s.io/kubernetes/pkg/api/v1/service"

Index

Functions

func ExternalPolicyLocal

func ExternalPolicyLocal(service *v1.Service) bool

ExternalPolicyLocal checks if service is externally accessible and has ETP = Local.

func ExternallyAccessible

func ExternallyAccessible(service *v1.Service) bool

ExternallyAccessible checks if service is externally accessible.

func GetLoadBalancerSourceRanges

func GetLoadBalancerSourceRanges(service *v1.Service) (utilnet.IPNetSet, error)

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 InternalPolicyLocal

func InternalPolicyLocal(service *v1.Service) bool

InternalPolicyLocal checks if service has ITP = Local.

func IsAllowAll

func IsAllowAll(ipnets utilnet.IPNetSet) bool

IsAllowAll checks whether the utilnet.IPNet allows traffic from 0.0.0.0/0

func NeedsHealthCheck

func NeedsHealthCheck(service *v1.Service) bool

NeedsHealthCheck checks if service needs health check.

Source Files

util.go

Version
v1.33.0 (latest)
Published
Apr 23, 2025
Platform
linux/amd64
Imports
4 packages
Last checked
3 hours ago

Tools for package owners.