ipvs

package
v0.0.0-...-c7e85b4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 6, 2019 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	IPTABLES_TABLE      = "raw"
	IPTABLES_PREROUTING = "PREROUTING"
	IPTABLES_CHAIN      = "IPVS-CONTROLLER"

	HighestRandomWeightScheduler = "hrw"
	MagLevScheduler              = "mh"
)

Variables

View Source
var (
	// TODO: make this as a config option
	SupportedIpvsSchedulers = []string{HighestRandomWeightScheduler, MagLevScheduler, ipvs.RoundRobin, ipvs.LeastConnection, ipvs.SourceHashing, ipvs.DestinationHashing}
)

Functions

func EnsureIptables

func EnsureIptables(ipt *iptables.IPTables, ipNets []*net.IPNet) error

func EnsureSysctlSettings

func EnsureSysctlSettings() error

func LoadIpvsSchedulerKernelModulesIfExist

func LoadIpvsSchedulerKernelModulesIfExist()

Types

type Destination

type Destination struct {
	*ipvs.Destination
}

Destination defines an IPVS destination (real server) in its entirety.

func NewIpvsDestination

func NewIpvsDestination(dst *ipvs.Destination) *Destination

func (*Destination) ID

func (d *Destination) ID() string

type Service

type Service struct {
	*ipvs.Service
}

Service defines an IPVS service in its entirety.

func NewIpvsService

func NewIpvsService(svc *ipvs.Service) *Service

func (*Service) ID

func (s *Service) ID() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL