Documentation ¶
Overview ¶
Package node contains the OpenShift SDN networking code that runs on the nodes
Index ¶
- Constants
- Variables
- func GetLinkDetails(ip string) (netlink.Link, *net.IPNet, error)
- func NewMultiTenantPlugin() osdnPolicy
- func NewNetworkPolicyPlugin() osdnPolicy
- func NewOVSController(ovsif ovs.Interface, pluginId int, localIP string, localMAC string) *ovsController
- func NewSingleTenantPlugin() osdnPolicy
- type Chain
- type NodeIPTables
- type OsdnNode
- func (plugin *OsdnNode) FinishSetupSDN() error
- func (node *OsdnNode) GetRunningPods(namespace string) ([]corev1.Pod, error)
- func (node *OsdnNode) ReloadIPTables() error
- func (plugin *OsdnNode) SetupEgressNetworkPolicy() error
- func (plugin *OsdnNode) SetupSDN() (bool, map[string]podNetworkInfo, error)
- func (node *OsdnNode) Start() error
- func (plugin *OsdnNode) UpdateEgressNetworkPolicyVNID(namespace string, oldVnid, newVnid uint32)
- func (node *OsdnNode) UpdatePod(pod corev1.Pod) error
- type OsdnNodeConfig
Constants ¶
View Source
const ( Br0 = "br0" Tun0 = "tun0" Vxlan0 = "vxlan0" )
View Source
const HostNetworkNamespace = "openshift-host-network"
View Source
const NetPolIsolationCookie = 1147582955
NetPolIsolationCookie is a random number to distinguish network policy isolation flows, only used by network policy functions
Variables ¶
View Source
var (
ErrorNetworkInterfaceNotFound = fmt.Errorf("could not find network interface")
)
Functions ¶
func NewMultiTenantPlugin ¶
func NewMultiTenantPlugin() osdnPolicy
func NewNetworkPolicyPlugin ¶
func NewNetworkPolicyPlugin() osdnPolicy
func NewOVSController ¶
func NewSingleTenantPlugin ¶
func NewSingleTenantPlugin() osdnPolicy
Types ¶
type NodeIPTables ¶
type NodeIPTables struct {
// contains filtered or unexported fields
}
func (*NodeIPTables) AddEgressIPRules ¶
func (n *NodeIPTables) AddEgressIPRules(egressIP, mark string) error
func (*NodeIPTables) DeleteEgressIPRules ¶
func (n *NodeIPTables) DeleteEgressIPRules(egressIP, mark string) error
func (*NodeIPTables) Setup ¶
func (n *NodeIPTables) Setup() error
func (*NodeIPTables) SyncEgressIPRules ¶
func (n *NodeIPTables) SyncEgressIPRules()
type OsdnNode ¶
type OsdnNode struct {
// contains filtered or unexported fields
}
func New ¶
func New(c *OsdnNodeConfig) (*OsdnNode, error)
Called by higher layers to create the plugin SDN node instance
func (*OsdnNode) FinishSetupSDN ¶
func (*OsdnNode) GetRunningPods ¶
func (*OsdnNode) ReloadIPTables ¶
func (*OsdnNode) SetupEgressNetworkPolicy ¶
func (*OsdnNode) UpdateEgressNetworkPolicyVNID ¶
type OsdnNodeConfig ¶
type OsdnNodeConfig struct { NodeName string NodeIP string PlatformType string OSDNClient osdnclient.Interface KClient kubernetes.Interface Recorder record.EventRecorder KubeInformers informers.SharedInformerFactory OSDNInformers osdninformers.SharedInformerFactory IPTables iptables.Interface MasqueradeBit *int32 OverrideMTU uint32 RoutableMTU uint32 }
Source Files ¶
Click to show internal directories.
Click to hide internal directories.