Documentation ¶
Index ¶
Constants ¶
View Source
const (
Mbit = 1000 * 1000
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EgressShaper ¶
type EgressShaper struct {
// contains filtered or unexported fields
}
ipset config: Name: caelus-offline-eth0 Type: hash:ip Revision: 1 Header: family inet hashsize 1024 maxelem 65536 Size in memory: 184 References: 1 Members: 192.168.2.27 192.168.2.28
func NewEgressShaper ¶
func NewEgressShaper(ifName string) (*EgressShaper, error)
NewEgressShaper creates an EgressShaper
func (*EgressShaper) EnsureEgressOfCgroup ¶
func (s *EgressShaper) EnsureEgressOfCgroup(pathInSubSystems []string) error
EnsureEgressOfCgroup ensure egress traffic limit for given cgroup paths
func (*EgressShaper) EnsureEgressOfIPs ¶
func (s *EgressShaper) EnsureEgressOfIPs(ipStrs []string) error
EnsureEgressOfIPs ensure egress traffic limit for given ip list
func (*EgressShaper) ReconcileInterface ¶
func (s *EgressShaper) ReconcileInterface() error
ReconcileInterface creates htb qdisc and htb class
Click to show internal directories.
Click to hide internal directories.