linuxclient

package
v1.8.1 Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2019 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Overview

Package linuxclient contains clients for local and remote management of both VPP and Linux configuration via Linux and default plugins.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DataChangeDSL

type DataChangeDSL interface {
	// Put initiates a chained sequence of data change DSL statements, declaring
	// new configurable objects or changing existing ones, e.g.:
	//     Put().LinuxInterface(&veth).VppInterface(&afpacket).BD(&BD) ... Send()
	// The set of available objects to be created or changed is defined by PutDSL.
	Put() PutDSL

	// Delete initiates a chained sequence of data change DSL statements,
	// removing existing configurable objects (by name), e.g:
	//     Delete().LinuxInterface(vethName).VppInterface(afpacketName).BD(BDName) ... Send()
	// The set of available objects to be removed is defined by DeleteDSL.
	Delete() DeleteDSL

	// Send propagates requested changes to the plugins.
	Send() vpp_clientv1.Reply
}

DataChangeDSL defines the Domain Specific Language (DSL) for data change of both Linux and VPP configuration. Use this interface to make your implementation independent of the local and any remote client. Every DSL statement (apart from Send) returns the receiver (possibly wrapped to change the scope of DSL), allowing the calls to be chained together conveniently in a single statement.

type DataResyncDSL

type DataResyncDSL interface {
	// LinuxInterface adds Linux interface to the RESYNC request.
	LinuxInterface(intf *interfaces.LinuxInterfaces_Interface) DataResyncDSL
	// LinuxInterface adds Linux ARP entry to the RESYNC request.
	LinuxArpEntry(intf *l3.LinuxStaticArpEntries_ArpEntry) DataResyncDSL
	// LinuxInterface adds Linux route to the RESYNC request.
	LinuxRoute(intf *l3.LinuxStaticRoutes_Route) DataResyncDSL

	// VppInterface adds VPP interface to the RESYNC request.
	VppInterface(intf *vpp_intf.Interfaces_Interface) DataResyncDSL
	// VppIPSecSPD adds VPP security policy database to the RESYNC request.
	VppIPSecSPD(spd *ipsec.SecurityPolicyDatabases_SPD) DataResyncDSL
	// VppIPSecSA adds VPP security association to the RESYNC request.
	VppIPSecSA(sa *ipsec.SecurityAssociations_SA) DataResyncDSL
	// VppIPSecTunnel adds VPP IPSec tunnel to the RESYNC request.
	VppIPSecTunnel(tunnel *ipsec.TunnelInterfaces_Tunnel) DataResyncDSL
	// BfdSession adds VPP bidirectional forwarding detection session
	// to the RESYNC request.
	BfdSession(val *vpp_bfd.SingleHopBFD_Session) DataResyncDSL
	// BfdAuthKeys adds VPP bidirectional forwarding detection key to the RESYNC
	// request.
	BfdAuthKeys(val *vpp_bfd.SingleHopBFD_Key) DataResyncDSL
	// BfdEchoFunction adds VPP bidirectional forwarding detection echo function
	// to the RESYNC request.
	BfdEchoFunction(val *vpp_bfd.SingleHopBFD_EchoFunction) DataResyncDSL
	// BD adds VPP Bridge Domain to the RESYNC request.
	BD(bd *vpp_l2.BridgeDomains_BridgeDomain) DataResyncDSL
	// BDFIB adds VPP L2 FIB to the RESYNC request.
	BDFIB(fib *vpp_l2.FibTable_FibEntry) DataResyncDSL
	// XConnect adds VPP Cross Connect to the RESYNC request.
	XConnect(xcon *vpp_l2.XConnectPairs_XConnectPair) DataResyncDSL
	// StaticRoute adds VPP L3 Static Route to the RESYNC request.
	StaticRoute(staticRoute *vpp_l3.StaticRoutes_Route) DataResyncDSL
	// ACL adds VPP Access Control List to the RESYNC request.
	ACL(acl *vpp_acl.AccessLists_Acl) DataResyncDSL
	// Arp adds VPP L3 ARP to the RESYNC request.
	Arp(arp *vpp_l3.ArpTable_ArpEntry) DataResyncDSL
	// ProxyArpInterfaces adds L3 proxy ARP interfaces to the RESYNC request.
	ProxyArpInterfaces(pArpIfs *vpp_l3.ProxyArpInterfaces_InterfaceList) DataResyncDSL
	// ProxyArpRanges adds L3 proxy ARP ranges to the RESYNC request.
	ProxyArpRanges(pArpRng *vpp_l3.ProxyArpRanges_RangeList) DataResyncDSL
	// L4Features adds L4 features to the RESYNC request
	L4Features(val *vpp_l4.L4Features) DataResyncDSL
	// AppNamespace adds VPP Application namespaces to the RESYNC request
	AppNamespace(appNs *vpp_l4.AppNamespaces_AppNamespace) DataResyncDSL
	// StnRule adds Stn rule to the RESYNC request.
	StnRule(stn *vpp_stn.STN_Rule) DataResyncDSL
	// NAT44Global adds a request to RESYNC global configuration for NAT44
	NAT44Global(nat *nat.Nat44Global) DataResyncDSL
	// NAT44DNat adds a request to RESYNC a new DNAT configuration
	NAT44DNat(dnat *nat.Nat44DNat_DNatConfig) DataResyncDSL
	// PuntSocketRegister adds request to RESYNC a new punt to host entry
	PuntSocketRegister(puntCfg *punt.Punt) DataResyncDSL

	// Send propagates the RESYNC request to the plugins.
	Send() vpp_clientv1.Reply
}

DataResyncDSL defines the Domain Specific Language (DSL) for data RESYNC of both Linux and VPP configuration. Use this interface to make your implementation independent of the local and any remote client. Each method (apart from Send) returns the receiver, allowing the calls to be chained together conveniently in a single statement.

type DeleteDSL

type DeleteDSL interface {
	// LinuxInterface adds a request to delete an existing Linux network
	// interface.
	LinuxInterface(ifaceName string) DeleteDSL
	// LinuxArpEntry adds a request to crete or update Linux ARP entry
	LinuxArpEntry(entryName string) DeleteDSL
	// LinuxRoute adds a request to crete or update Linux route
	LinuxRoute(routeName string) DeleteDSL

	// VppInterface adds a request to delete an existing VPP network interface.
	VppInterface(ifaceName string) DeleteDSL
	// VppIPSecSPD adds a request to create or update VPP security policy database
	VppIPSecSPD(spdName string) DeleteDSL
	// VppIPSecSA adds a request to create or update VPP security association
	VppIPSecSA(saName string) DeleteDSL
	// VppIPSecTunnel adds a request to create or update VPP IPSec tunnel interface
	VppIPSecTunnel(tunName string) DeleteDSL
	// BfdSession adds a request to delete an existing VPP bidirectional
	// forwarding detection session.
	BfdSession(bfdSessionIfaceName string) DeleteDSL
	// BfdAuthKeys adds a request to delete an existing VPP bidirectional
	// forwarding detection key.
	BfdAuthKeys(bfdKey string) DeleteDSL
	// BfdEchoFunction adds a request to delete an existing VPP bidirectional
	// forwarding detection echo function.
	BfdEchoFunction(bfdEchoName string) DeleteDSL
	// BD adds a request to delete an existing VPP Bridge Domain.
	BD(bdName string) DeleteDSL
	// FIB adds a request to delete an existing VPP L2 Forwarding Information
	// Base.
	BDFIB(bdName string, mac string) DeleteDSL
	// XConnect adds a request to delete an existing VPP Cross Connect.
	XConnect(rxIfaceName string) DeleteDSL
	// StaticRoute adds a request to delete an existing VPP L3 Static Route.
	StaticRoute(vrf uint32, dstAddr string, nextHopAddr string) DeleteDSL
	// ACL adds a request to delete an existing VPP Access Control List.
	ACL(aclName string) DeleteDSL
	// L4Features adds a request to enable or disable L4 features
	L4Features() DeleteDSL
	// AppNamespace adds a request to delete VPP Application namespace
	// Note: current version does not support application namespace deletion
	AppNamespace(id string) DeleteDSL
	// Arp adds a request to delete an existing VPP L3 ARP.
	Arp(ifaceName string, ipAddr string) DeleteDSL
	// ProxyArpInterfaces adds a request to delete an existing VPP L3 proxy ARP interfaces
	ProxyArpInterfaces(label string) DeleteDSL
	// ProxyArpRanges adds a request to delete an existing VPP L3 proxy ARP ranges
	ProxyArpRanges(label string) DeleteDSL
	// StnRule adds a request to delete an existing VPP Stn rule.
	StnRule(ruleName string) DeleteDSL
	// NAT44Global adds a request to remove global configuration for NAT44
	NAT44Global() DeleteDSL
	// NAT44DNat adds a request to delete a new DNAT configuration
	NAT44DNat(label string) DeleteDSL
	// PuntSocketDeregister adds request to de-register an existing punt to host entry
	PuntSocketDeregister(puntName string) DeleteDSL

	// Put changes the DSL mode to allow configuration editing.
	// See documentation for DataChangeDSL.Put().
	Put() PutDSL

	// Send propagates requested changes to the plugins.
	Send() vpp_clientv1.Reply
}

DeleteDSL is a subset of data change DSL statements, used to remove existing Linux or VPP configuration.

type PutDSL

type PutDSL interface {
	// LinuxInterface adds a request to create or update Linux network interface.
	LinuxInterface(val *interfaces.LinuxInterfaces_Interface) PutDSL
	// LinuxArpEntry adds a request to crete or update Linux ARP entry
	LinuxArpEntry(val *l3.LinuxStaticArpEntries_ArpEntry) PutDSL
	// LinuxRoute adds a request to crete or update Linux route
	LinuxRoute(val *l3.LinuxStaticRoutes_Route) PutDSL

	// VppInterface adds a request to create or update VPP network interface.
	VppInterface(val *vpp_intf.Interfaces_Interface) PutDSL
	// VppIPSecSPD adds a request to create or update VPP security policy database
	VppIPSecSPD(val *ipsec.SecurityPolicyDatabases_SPD) PutDSL
	// VppIPSecSA adds a request to create or update VPP security association
	VppIPSecSA(val *ipsec.SecurityAssociations_SA) PutDSL
	// VppIPSecTunnel adds a request to create or update VPP IPSec tunnel interface
	VppIPSecTunnel(val *ipsec.TunnelInterfaces_Tunnel) PutDSL
	// BfdSession adds a request to create or update VPP bidirectional
	// forwarding detection session.
	BfdSession(val *vpp_bfd.SingleHopBFD_Session) PutDSL
	// BfdAuthKeys adds a request to create or update VPP bidirectional
	// forwarding detection key.
	BfdAuthKeys(val *vpp_bfd.SingleHopBFD_Key) PutDSL
	// BfdEchoFunction adds a request to create or update VPP bidirectional
	// forwarding detection echo function.
	BfdEchoFunction(val *vpp_bfd.SingleHopBFD_EchoFunction) PutDSL
	// BD adds a request to create or update VPP Bridge Domain.
	BD(val *vpp_l2.BridgeDomains_BridgeDomain) PutDSL
	// BDFIB adds a request to create or update VPP L2 Forwarding Information Base.
	BDFIB(fib *vpp_l2.FibTable_FibEntry) PutDSL
	// XConnect adds a request to create or update VPP Cross Connect.
	XConnect(val *vpp_l2.XConnectPairs_XConnectPair) PutDSL
	// StaticRoute adds a request to create or update VPP L3 Static Route.
	StaticRoute(val *vpp_l3.StaticRoutes_Route) PutDSL
	// ACL adds a request to create or update VPP Access Control List.
	ACL(acl *vpp_acl.AccessLists_Acl) PutDSL
	// Arp adds a request to create or update VPP L3 ARP.
	Arp(arp *vpp_l3.ArpTable_ArpEntry) PutDSL
	// ProxyArpInterfaces adds a request to create or update VPP L3 proxy ARP interfaces
	ProxyArpInterfaces(pArpIfs *vpp_l3.ProxyArpInterfaces_InterfaceList) PutDSL
	// ProxyArpRanges adds a request to create or update VPP L3 proxy ARP ranges
	ProxyArpRanges(pArpRng *vpp_l3.ProxyArpRanges_RangeList) PutDSL
	// PuntSocketRegister adds request to register a new punt to host entry
	PuntSocketRegister(puntCfg *punt.Punt) PutDSL
	// L4Features adds a request to enable or disable L4 features
	L4Features(val *vpp_l4.L4Features) PutDSL
	// AppNamespace adds a request to create or update VPP Application namespace
	AppNamespace(appNs *vpp_l4.AppNamespaces_AppNamespace) PutDSL
	// StnRule adds a request to create or update VPP Stn rule.
	StnRule(stn *vpp_stn.STN_Rule) PutDSL
	// NAT44Global adds a request to set global configuration for NAT44
	NAT44Global(nat *nat.Nat44Global) PutDSL
	// NAT44DNat adds a request to create a new DNAT configuration
	NAT44DNat(dnat *nat.Nat44DNat_DNatConfig) PutDSL

	// Delete changes the DSL mode to allow removing an existing configuration.
	// See documentation for DataChangeDSL.Delete().
	Delete() DeleteDSL

	// Send propagates requested changes to the plugins.
	Send() vpp_clientv1.Reply
}

PutDSL is a subset of data change DSL statements, used to declare new Linux or VPP configuration or change existing one.

Directories

Path Synopsis
Package dbadapter implements Domain Specific Language (DSL) for resync and change of VPP and Linux configuration.
Package dbadapter implements Domain Specific Language (DSL) for resync and change of VPP and Linux configuration.
Package localclient implements client for local management of VPP and Linux configuration.
Package localclient implements client for local management of VPP and Linux configuration.
Package remoteclient implements client for remote management of VPP and Linux configuration.
Package remoteclient implements client for remote management of VPP and Linux configuration.

Jump to

Keyboard shortcuts

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