Documentation ¶
Index ¶
- Constants
- func AddOrUpdateU2OFilterOpenFlow(client *ovs.Client, bridgeName, gatewayIP, u2oIP, underlayNic string) error
- func BridgeExists(name string) (bool, error)
- func Bridges() ([]string, error)
- func CheckAndUpdateHtbQos(podName, podNamespace, ifaceID string, queueIfaceUIDMap map[string]string) error
- func CleanDuplicatePort(ifaceID, portName string)
- func CleanLostInterface()
- func ClearHtbQosQueue(podName, podNamespace, iface string) error
- func ClearPodBandwidth(podName, podNamespace, ifaceID string) error
- func ClearPortQosBinding(ifaceID string) error
- func ConfigInterfaceMirror(globalMirror bool, open, iface string) error
- func ConstructWaitForNameNotExistsOperation(name, table string) ovsdb.Operation
- func ConstructWaitForUniqueOperation(table, column string, value interface{}) ovsdb.Operation
- func DeleteAllU2OFilterOpenFlow(client *ovs.Client, bridgeName, protocol string) error
- func Exec(args ...string) (string, error)
- func GetInterfacePodNs(iface string) (string, error)
- func GetLocalnetName(subnet string) string
- func GetQosList(podName, podNamespace, ifaceID string) ([]string, error)
- func GetResidualInternalPorts() []string
- func GetSgPortGroupName(sgName string) string
- func GetSgV4AssociatedName(sgName string) string
- func GetSgV6AssociatedName(sgName string) string
- func IsHtbQos(iface string) (bool, error)
- func IsUserspaceDataPath() (is bool, err error)
- func ListExternalIDs(table string) (map[string]string, error)
- func ListQosQueueIDs() (map[string]string, error)
- func LogicalRouterPortName(lr, ls string) string
- func LogicalSwitchPortName(lr, ls string) string
- func PodNameToPortName(pod, namespace, provider string) string
- func PortExists(name string) (bool, error)
- func SetHtbQosQueueRecord(podName, podNamespace, iface string, maxRateBPS int, ...) (string, error)
- func SetInterfaceBandwidth(podName, podNamespace, iface, ingress, egress string) error
- func SetNetemQos(podName, podNamespace, iface, latency, limit, loss, jitter string) error
- func SetPortTag(port, tag string) error
- func SetQosQueueBinding(podName, podNamespace, ifName, iface, queueUID string, ...) error
- func UpdateOVSVsctlLimiter(c int32)
- func ValidatePortVendor(port string) (bool, error)
- type ACL
- type ACLMatch
- type AddressSet
- type AndACLMatch
- type BFD
- type Chassis
- type Common
- type DHCPOptions
- type DHCPOptionsUUIDs
- type LegacyClient
- func (c LegacyClient) DestroyChassis(uuid string) error
- func (c LegacyClient) DestroyGateways(uuids []string) error
- func (c LegacyClient) DestroyPortBindings(uuids []string) error
- func (c LegacyClient) DestroyRoutes(uuids []string) error
- func (c LegacyClient) DestroyTableWithUUID(uuid, table string) error
- func (c LegacyClient) FindUUIDWithAttrInTable(attribute, value, table string) ([]string, error)
- func (c LegacyClient) GetAzUUID(az string) (string, error)
- func (c LegacyClient) GetGatewayUUIDsInOneAZ(uuid string) ([]string, error)
- func (c LegacyClient) GetPortBindingUUIDsInOneAZ(uuid string) ([]string, error)
- func (c LegacyClient) GetRouteUUIDsInOneAZ(uuid string) ([]string, error)
- func (c LegacyClient) GetTs() ([]string, error)
- func (c LegacyClient) GetTsSubnet(ts string) (string, error)
- type Limiter
- type LoadBalancer
- type LoadBalancerHealthCheck
- type LogicalRouter
- type LogicalRouterPolicy
- type LogicalRouterPort
- type LogicalRouterStaticRoute
- type LogicalSwitch
- type LogicalSwitchPort
- type NAT
- type NBGlobal
- type NbClient
- type OVNNbClient
- func (c *OVNNbClient) ACLExists(parent, direction, priority, match string) (bool, error)
- func (c *OVNNbClient) AddLoadBalancerHealthCheck(lbName, vipEndpoint string, externals map[string]string) error
- func (c *OVNNbClient) AddLogicalRouterPolicy(lrName string, priority int, match, action string, nextHops []string, ...) error
- func (c *OVNNbClient) AddLogicalRouterPort(lr, name, mac, networks string) error
- func (c *OVNNbClient) AddLogicalRouterStaticRoute(lrName, routeTable, policy, ipPrefix string, bfdID *string, nexthops ...string) error
- func (c *OVNNbClient) AddNat(lrName, natType, externalIP, logicalIP, logicalMac, port string, ...) error
- func (c *OVNNbClient) AddressSetExists(name string) (bool, error)
- func (c *OVNNbClient) AddressSetUpdateAddress(asName string, addresses ...string) error
- func (c *OVNNbClient) ClearLogicalRouterPolicy(lrName string) error
- func (c *OVNNbClient) ClearLogicalRouterStaticRoute(lrName string) error
- func (c *OVNNbClient) CreateAcls(parentName, parentType string, acls ...*ovnnb.ACL) error
- func (c *OVNNbClient) CreateAclsOps(parentName, parentType string, acls ...*ovnnb.ACL) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) CreateAddressSet(asName string, externalIDs map[string]string) error
- func (c *OVNNbClient) CreateBFD(lrpName, dstIP string, minRx, minTx, detectMult int) (*ovnnb.BFD, error)
- func (c *OVNNbClient) CreateBareACL(parentName, direction, priority, match, action string) error
- func (c *OVNNbClient) CreateBareLogicalSwitch(lsName string) error
- func (c *OVNNbClient) CreateBareLogicalSwitchPort(lsName, lspName, ip, mac string) error
- func (c *OVNNbClient) CreateDHCPOptions(lsName, cidr, options string) error
- func (c *OVNNbClient) CreateGatewayACL(lsName, pgName, gateway string) error
- func (c *OVNNbClient) CreateGatewayChassises(lrpName string, chassises ...string) error
- func (c *OVNNbClient) CreateGatewayChassisesOp(lrpName string, chassises []string) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) CreateGatewayLogicalSwitch(lsName, lrName, provider, ip, mac string, vlanID int, chassises ...string) error
- func (c *OVNNbClient) CreateLoadBalancer(lbName, protocol, selectFields string) error
- func (c *OVNNbClient) CreateLoadBalancerHealthCheck(lbName, vipEndpoint string, lbhc *ovnnb.LoadBalancerHealthCheck) error
- func (c *OVNNbClient) CreateLocalnetLogicalSwitchPort(lsName, lspName, provider, cidrBlock string, vlanID int) error
- func (c *OVNNbClient) CreateLogicalPatchPort(lsName, lrName, lspName, lrpName, ip, mac string, chassises ...string) error
- func (c *OVNNbClient) CreateLogicalRouter(lrName string) error
- func (c *OVNNbClient) CreateLogicalRouterPolicies(lrName string, policies ...*ovnnb.LogicalRouterPolicy) error
- func (c *OVNNbClient) CreateLogicalRouterPort(lrName, lrpName, mac string, networks []string) error
- func (c *OVNNbClient) CreateLogicalRouterPortOp(lrp *ovnnb.LogicalRouterPort, lrName string) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) CreateLogicalRouterStaticRoutes(lrName string, routes ...*ovnnb.LogicalRouterStaticRoute) error
- func (c *OVNNbClient) CreateLogicalSwitch(lsName, lrName, cidrBlock, gateway string, needRouter, randomAllocateGW bool) error
- func (c *OVNNbClient) CreateLogicalSwitchPort(lsName, lspName, ip, mac, podName, namespace string, portSecurity bool, ...) error
- func (c *OVNNbClient) CreateLogicalSwitchPortOp(lsp *ovnnb.LogicalSwitchPort, lsName string) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) CreateNats(lrName string, nats ...*ovnnb.NAT) error
- func (c *OVNNbClient) CreateNbGlobal(nbGlobal *ovnnb.NBGlobal) error
- func (c *OVNNbClient) CreateNodeACL(pgName, nodeIPStr, joinIPStr string) error
- func (c *OVNNbClient) CreatePeerRouterPort(localRouter, remoteRouter, localRouterPortIP string) error
- func (c *OVNNbClient) CreatePortGroup(pgName string, externalIDs map[string]string) error
- func (c *OVNNbClient) CreateRouterPortOp(lsName, lrName, lspName, lrpName, ip, mac string) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) CreateSgBaseACL(sgName, direction string) error
- func (c *OVNNbClient) CreateSgDenyAllACL(sgName string) error
- func (c *OVNNbClient) CreateVirtualLogicalSwitchPorts(lsName string, ips ...string) error
- func (c *OVNNbClient) DHCPOptionsExists(lsName, cidr string) (bool, error)
- func (c *OVNNbClient) DeleteACL(parentName, parentType, direction, priority, match string) error
- func (c *OVNNbClient) DeleteAcls(parentName, parentType, direction string, externalIDs map[string]string) error
- func (c *OVNNbClient) DeleteAclsOps(parentName, parentType, direction string, externalIDs map[string]string) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) DeleteAddressSet(asName string) error
- func (c *OVNNbClient) DeleteAddressSets(externalIDs map[string]string) error
- func (c *OVNNbClient) DeleteBFD(lrpName, dstIP string) error
- func (c *OVNNbClient) DeleteDHCPOptions(lsName, protocol string) error
- func (c *OVNNbClient) DeleteDHCPOptionsByUUIDs(uuidList ...string) error
- func (c *OVNNbClient) DeleteGatewayChassisOp(chassisName string) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) DeleteGatewayChassises(lrpName string, chassises []string) error
- func (c *OVNNbClient) DeleteLoadBalancer(lbName string) error
- func (c *OVNNbClient) DeleteLoadBalancerHealthCheck(lbName, vip string) error
- func (c *OVNNbClient) DeleteLoadBalancerHealthCheckOp(lbName, vip string) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) DeleteLoadBalancerHealthChecks(filter func(lb *ovnnb.LoadBalancerHealthCheck) bool) error
- func (c *OVNNbClient) DeleteLoadBalancerOp(lbName string) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) DeleteLoadBalancers(filter func(lb *ovnnb.LoadBalancer) bool) error
- func (c *OVNNbClient) DeleteLogicalGatewaySwitch(lsName, lrName string) error
- func (c *OVNNbClient) DeleteLogicalRouter(lrName string) error
- func (c *OVNNbClient) DeleteLogicalRouterPolicies(lrName string, priority int, externalIDs map[string]string) error
- func (c *OVNNbClient) DeleteLogicalRouterPolicy(lrName string, priority int, match string) error
- func (c *OVNNbClient) DeleteLogicalRouterPolicyByNexthop(lrName string, priority int, nexthop string) error
- func (c *OVNNbClient) DeleteLogicalRouterPolicyByUUID(lrName, uuid string) error
- func (c *OVNNbClient) DeleteLogicalRouterPort(lrpName string) error
- func (c *OVNNbClient) DeleteLogicalRouterPortOp(lrpName string) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) DeleteLogicalRouterPorts(externalIDs map[string]string, filter func(lrp *ovnnb.LogicalRouterPort) bool) error
- func (c *OVNNbClient) DeleteLogicalRouterStaticRoute(lrName string, routeTable, policy *string, ipPrefix, nexthop string) error
- func (c *OVNNbClient) DeleteLogicalSwitch(lsName string) error
- func (c *OVNNbClient) DeleteLogicalSwitchOp(lsName string) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) DeleteLogicalSwitchPort(lspName string) error
- func (c *OVNNbClient) DeleteLogicalSwitchPortOp(lspName string) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) DeleteLogicalSwitchPorts(externalIDs map[string]string, filter func(lrp *ovnnb.LogicalSwitchPort) bool) error
- func (c *OVNNbClient) DeleteNat(lrName, natType, externalIP, logicalIP string) error
- func (c *OVNNbClient) DeleteNats(lrName, natType, logicalIP string) error
- func (c *OVNNbClient) DeleteNbGlobal() error
- func (c *OVNNbClient) DeletePortGroup(pgName string) error
- func (c *OVNNbClient) DeleteRouterPolicy(lr *ovnnb.LogicalRouter, uuid string) error
- func (c *OVNNbClient) DeleteSecurityGroup(sgName string) error
- func (c *OVNNbClient) EnablePortLayer2forward(lspName string) error
- func (c *OVNNbClient) GatewayChassisExist(name string) (bool, error)
- func (c *OVNNbClient) GetACL(parent, direction, priority, match string, ignoreNotFound bool) (*ovnnb.ACL, error)
- func (c *OVNNbClient) GetAddressSet(asName string, ignoreNotFound bool) (*ovnnb.AddressSet, error)
- func (c *OVNNbClient) GetDHCPOptions(lsName, protocol string, ignoreNotFound bool) (*ovnnb.DHCPOptions, error)
- func (c *OVNNbClient) GetEntityInfo(entity interface{}) error
- func (c *OVNNbClient) GetGatewayChassis(name string, ignoreNotFound bool) (*ovnnb.GatewayChassis, error)
- func (c *OVNNbClient) GetLoadBalancer(lbName string, ignoreNotFound bool) (*ovnnb.LoadBalancer, error)
- func (c *OVNNbClient) GetLoadBalancerHealthCheck(lbName, vipEndpoint string, ignoreNotFound bool) (*ovnnb.LoadBalancer, *ovnnb.LoadBalancerHealthCheck, error)
- func (c *OVNNbClient) GetLogicalRouter(lrName string, ignoreNotFound bool) (*ovnnb.LogicalRouter, error)
- func (c *OVNNbClient) GetLogicalRouterPoliciesByExtID(lrName, key, value string) ([]*ovnnb.LogicalRouterPolicy, error)
- func (c *OVNNbClient) GetLogicalRouterPolicy(lrName string, priority int, match string, ignoreNotFound bool) ([]*ovnnb.LogicalRouterPolicy, error)
- func (c *OVNNbClient) GetLogicalRouterPolicyByUUID(uuid string) (*ovnnb.LogicalRouterPolicy, error)
- func (c *OVNNbClient) GetLogicalRouterPort(lrpName string, ignoreNotFound bool) (*ovnnb.LogicalRouterPort, error)
- func (c *OVNNbClient) GetLogicalRouterPortByUUID(uuid string) (*ovnnb.LogicalRouterPort, error)
- func (c *OVNNbClient) GetLogicalRouterStaticRoute(lrName, routeTable, policy, ipPrefix, nexthop string, ignoreNotFound bool) (*ovnnb.LogicalRouterStaticRoute, error)
- func (c *OVNNbClient) GetLogicalRouterStaticRouteByUUID(uuid string) (*ovnnb.LogicalRouterStaticRoute, error)
- func (c *OVNNbClient) GetLogicalSwitch(lsName string, ignoreNotFound bool) (*ovnnb.LogicalSwitch, error)
- func (c *OVNNbClient) GetLogicalSwitchPort(lspName string, ignoreNotFound bool) (*ovnnb.LogicalSwitchPort, error)
- func (c *OVNNbClient) GetNATByUUID(uuid string) (*ovnnb.NAT, error)
- func (c *OVNNbClient) GetNat(lrName, natType, externalIP, logicalIP string, ignoreNotFound bool) (*ovnnb.NAT, error)
- func (c *OVNNbClient) GetNbGlobal() (*ovnnb.NBGlobal, error)
- func (c *OVNNbClient) GetPortGroup(pgName string, ignoreNotFound bool) (*ovnnb.PortGroup, error)
- func (c *OVNNbClient) ListAcls(direction string, externalIDs map[string]string) ([]ovnnb.ACL, error)
- func (c *OVNNbClient) ListAddressSets(externalIDs map[string]string) ([]ovnnb.AddressSet, error)
- func (c *OVNNbClient) ListBFD(lrpName, dstIP string) ([]ovnnb.BFD, error)
- func (c *OVNNbClient) ListDHCPOptions(needVendorFilter bool, externalIDs map[string]string) ([]ovnnb.DHCPOptions, error)
- func (c *OVNNbClient) ListLoadBalancerHealthChecks(filter func(lbhc *ovnnb.LoadBalancerHealthCheck) bool) ([]ovnnb.LoadBalancerHealthCheck, error)
- func (c *OVNNbClient) ListLoadBalancers(filter func(lb *ovnnb.LoadBalancer) bool) ([]ovnnb.LoadBalancer, error)
- func (c *OVNNbClient) ListLogicalRouter(needVendorFilter bool, filter func(lr *ovnnb.LogicalRouter) bool) ([]ovnnb.LogicalRouter, error)
- func (c *OVNNbClient) ListLogicalRouterPolicies(lrName string, priority int, externalIDs map[string]string, ...) ([]*ovnnb.LogicalRouterPolicy, error)
- func (c *OVNNbClient) ListLogicalRouterPorts(externalIDs map[string]string, filter func(lrp *ovnnb.LogicalRouterPort) bool) ([]ovnnb.LogicalRouterPort, error)
- func (c *OVNNbClient) ListLogicalRouterStaticRoutes(lrName string, routeTable, policy *string, ipPrefix string, ...) ([]*ovnnb.LogicalRouterStaticRoute, error)
- func (c *OVNNbClient) ListLogicalRouterStaticRoutesByOption(lrName, _, key, value string) ([]*ovnnb.LogicalRouterStaticRoute, error)
- func (c *OVNNbClient) ListLogicalSwitch(needVendorFilter bool, filter func(ls *ovnnb.LogicalSwitch) bool) ([]ovnnb.LogicalSwitch, error)
- func (c *OVNNbClient) ListLogicalSwitchPorts(needVendorFilter bool, externalIDs map[string]string, ...) ([]ovnnb.LogicalSwitchPort, error)
- func (c *OVNNbClient) ListLogicalSwitchPortsWithLegacyExternalIDs() ([]ovnnb.LogicalSwitchPort, error)
- func (c *OVNNbClient) ListNats(lrName, natType, logicalIP string, externalIDs map[string]string) ([]*ovnnb.NAT, error)
- func (c *OVNNbClient) ListNormalLogicalSwitchPorts(needVendorFilter bool, externalIDs map[string]string) ([]ovnnb.LogicalSwitchPort, error)
- func (c *OVNNbClient) ListPortGroups(externalIDs map[string]string) ([]ovnnb.PortGroup, error)
- func (c *OVNNbClient) LoadBalancerAddHealthCheck(lbName, vipEndpoint string, ignoreHealthCheck bool, ...) error
- func (c *OVNNbClient) LoadBalancerAddIPPortMapping(lbName, vipEndpoint string, mappings map[string]string) error
- func (c *OVNNbClient) LoadBalancerAddVip(lbName, vip string, backends ...string) error
- func (c *OVNNbClient) LoadBalancerDeleteHealthCheck(lbName, uuid string) error
- func (c *OVNNbClient) LoadBalancerDeleteIPPortMapping(lbName, vipEndpoint string) error
- func (c *OVNNbClient) LoadBalancerDeleteVip(lbName, vipEndpoint string, ignoreHealthCheck bool) error
- func (c *OVNNbClient) LoadBalancerExists(lbName string) (bool, error)
- func (c *OVNNbClient) LoadBalancerHealthCheckExists(lbName, vipEndpoint string) (bool, error)
- func (c *OVNNbClient) LoadBalancerOp(lbName string, mutationsFunc ...func(lb *ovnnb.LoadBalancer) []model.Mutation) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) LoadBalancerUpdateHealthCheckOp(lbName string, lbhcUUIDs []string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) LoadBalancerUpdateIPPortMapping(lbName, vipEndpoint string, ipPortMappings map[string]string) error
- func (c *OVNNbClient) LogicalRouterExists(name string) (bool, error)
- func (c *OVNNbClient) LogicalRouterOp(lrName string, mutationsFunc ...func(lr *ovnnb.LogicalRouter) *model.Mutation) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) LogicalRouterPortExists(lrpName string) (bool, error)
- func (c *OVNNbClient) LogicalRouterPortOp(lrpName string, ...) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) LogicalRouterPortUpdateGatewayChassisOp(lrpName string, uuids []string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) LogicalRouterStaticRouteExists(lrName, routeTable, policy, ipPrefix, nexthop string) (bool, error)
- func (c *OVNNbClient) LogicalRouterUpdateLoadBalancers(lrName string, op ovsdb.Mutator, lbNames ...string) error
- func (c *OVNNbClient) LogicalRouterUpdateNatOp(lrName string, natUUIDs []string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) LogicalRouterUpdatePolicyOp(lrName string, policyUUIDs []string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) LogicalRouterUpdatePortOp(lrName, lrpUUID string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) LogicalRouterUpdateStaticRouteOp(lrName string, routeUUIDs []string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) LogicalSwitchAddPort(lsName, lspName string) error
- func (c *OVNNbClient) LogicalSwitchDelPort(lsName, lspName string) error
- func (c *OVNNbClient) LogicalSwitchExists(lsName string) (bool, error)
- func (c *OVNNbClient) LogicalSwitchOp(lsName string, mutationsFunc ...func(ls *ovnnb.LogicalSwitch) *model.Mutation) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) LogicalSwitchPortExists(name string) (bool, error)
- func (c *OVNNbClient) LogicalSwitchUpdateLoadBalancerOp(lsName string, lbUUIDs []string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) LogicalSwitchUpdateLoadBalancers(lsName string, op ovsdb.Mutator, lbNames ...string) error
- func (c *OVNNbClient) LogicalSwitchUpdateOtherConfig(lsName string, op ovsdb.Mutator, otherConfig map[string]string) error
- func (c *OVNNbClient) LogicalSwitchUpdateOtherConfigOp(lsName string, otherConfig map[string]string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) LogicalSwitchUpdatePortOp(lsName, lspUUID string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) NatExists(lrName, natType, externalIP, logicalIP string) (bool, error)
- func (c *OVNNbClient) PortGroupAddPorts(pgName string, lspNames ...string) error
- func (c *OVNNbClient) PortGroupExists(pgName string) (bool, error)
- func (c *OVNNbClient) PortGroupRemovePorts(pgName string, lspNames ...string) error
- func (c *OVNNbClient) PortGroupSetPorts(pgName string, ports []string) error
- func (c *OVNNbClient) PortGroupUpdatePorts(pgName string, op ovsdb.Mutator, lspNames ...string) error
- func (c *OVNNbClient) RemoveLogicalPatchPort(lspName, lrpName string) error
- func (c *OVNNbClient) SGLostACL(sg *kubeovnv1.SecurityGroup) (bool, error)
- func (c *OVNNbClient) SetACLLog(pgName string, logEnable, isIngress bool) error
- func (c *OVNNbClient) SetAzName(azName string) error
- func (c *OVNNbClient) SetICAutoRoute(enable bool, blackList []string) error
- func (c *OVNNbClient) SetLBCIDR(serviceCIDR string) error
- func (c *OVNNbClient) SetLoadBalancerAffinityTimeout(lbName string, timeout int) error
- func (c *OVNNbClient) SetLogicalSwitchPortArpProxy(lspName string, enableArpProxy bool) error
- func (c *OVNNbClient) SetLogicalSwitchPortExternalIDs(lspName string, externalIDs map[string]string) error
- func (c *OVNNbClient) SetLogicalSwitchPortSecurity(portSecurity bool, lspName, mac, ips, vips string) error
- func (c *OVNNbClient) SetLogicalSwitchPortSecurityGroup(lsp *ovnnb.LogicalSwitchPort, op string, sgs ...string) ([]string, error)
- func (c *OVNNbClient) SetLogicalSwitchPortVirtualParents(lsName, parents string, ips ...string) error
- func (c *OVNNbClient) SetLogicalSwitchPortVlanTag(lspName string, vlanID int) error
- func (c *OVNNbClient) SetLogicalSwitchPortsSecurityGroup(sgName, op string) error
- func (c *OVNNbClient) SetLogicalSwitchPrivate(lsName, cidrBlock, nodeSwitchCIDR string, allowSubnets []string) error
- func (c *OVNNbClient) SetLsCtSkipDstLportIPs(enabled bool) error
- func (c *OVNNbClient) SetLsDnatModDlDst(enabled bool) error
- func (c *OVNNbClient) SetNbGlobalOptions(key string, value interface{}) error
- func (c *OVNNbClient) SetUseCtInvMatch() error
- func (c *OVNNbClient) Transact(method string, operations []ovsdb.Operation) error
- func (c *OVNNbClient) UpdateACL(acl *ovnnb.ACL, fields ...interface{}) error
- func (c *OVNNbClient) UpdateAddressSet(as *ovnnb.AddressSet, fields ...interface{}) error
- func (c *OVNNbClient) UpdateDHCPOptions(subnet *kubeovnv1.Subnet, mtu int) (*DHCPOptionsUUIDs, error)
- func (c *OVNNbClient) UpdateDnatAndSnat(lrName, externalIP, logicalIP, lspName, externalMac, gatewayType string) error
- func (c *OVNNbClient) UpdateEgressACLOps(pgName, asEgressName, asExceptName, protocol string, ...) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) UpdateIngressACLOps(pgName, asIngressName, asExceptName, protocol string, ...) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) UpdateLoadBalancer(lb *ovnnb.LoadBalancer, fields ...interface{}) error
- func (c *OVNNbClient) UpdateLoadBalancerHealthCheck(lbhc *ovnnb.LoadBalancerHealthCheck, fields ...interface{}) error
- func (c *OVNNbClient) UpdateLogicalRouter(lr *ovnnb.LogicalRouter, fields ...interface{}) error
- func (c *OVNNbClient) UpdateLogicalRouterOp(lr *ovnnb.LogicalRouter, fields ...interface{}) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) UpdateLogicalRouterPort(lrp *ovnnb.LogicalRouterPort, fields ...interface{}) error
- func (c *OVNNbClient) UpdateLogicalRouterPortOptions(lrpName string, options map[string]string) error
- func (c *OVNNbClient) UpdateLogicalRouterPortRA(lrpName, ipv6RAConfigsStr string, enableIPv6RA bool) error
- func (c *OVNNbClient) UpdateLogicalRouterStaticRoute(route *ovnnb.LogicalRouterStaticRoute, fields ...interface{}) error
- func (c *OVNNbClient) UpdateLogicalSwitchACL(lsName string, subnetAcls []kubeovnv1.ACL) error
- func (c *OVNNbClient) UpdateLogicalSwitchPort(lsp *ovnnb.LogicalSwitchPort, fields ...interface{}) error
- func (c *OVNNbClient) UpdateLogicalSwitchPortOp(lsp *ovnnb.LogicalSwitchPort, fields ...interface{}) ([]ovsdb.Operation, error)
- func (c *OVNNbClient) UpdateNat(nat *ovnnb.NAT, fields ...interface{}) error
- func (c *OVNNbClient) UpdateNbGlobal(nbGlobal *ovnnb.NBGlobal, fields ...interface{}) error
- func (c *OVNNbClient) UpdatePortGroup(pg *ovnnb.PortGroup, fields ...interface{}) error
- func (c *OVNNbClient) UpdateSgACL(sg *kubeovnv1.SecurityGroup, direction string) error
- func (c *OVNNbClient) UpdateSnat(lrName, externalIP, logicalIP string) error
- type OVNSbClient
- func (c *OVNSbClient) DeleteChassis(chassisName string) error
- func (c *OVNSbClient) DeleteChassisByHost(nodeName string) error
- func (c *OVNSbClient) GetAllChassisByHost(nodeName string) (*[]ovnsb.Chassis, error)
- func (c *OVNSbClient) GetChassis(chassisName string, ignoreNotFound bool) (*ovnsb.Chassis, error)
- func (c *OVNSbClient) GetChassisByHost(nodeName string) (*ovnsb.Chassis, error)
- func (c *OVNSbClient) GetEntityInfo(entity interface{}) error
- func (c *OVNSbClient) GetKubeOvnChassisses() (*[]ovnsb.Chassis, error)
- func (c *OVNSbClient) ListChassis() (*[]ovnsb.Chassis, error)
- func (c *OVNSbClient) Transact(method string, operations []ovsdb.Operation) error
- func (c *OVNSbClient) UpdateChassis(chassis *ovnsb.Chassis, fields ...interface{}) error
- func (c *OVNSbClient) UpdateChassisTag(chassisName, nodeName string) error
- type OrACLMatch
- type PortGroup
- type SbClient
Constants ¶
const ( OVNIcNbCtl = "ovn-ic-nbctl" OVNIcSbCtl = "ovn-ic-sbctl" OvsVsCtl = "ovs-vsctl" MayExist = "--may-exist" IfExists = "--if-exists" OVSDBWaitTimeout = 0 )
Variables ¶
This section is empty.
Functions ¶
func AddOrUpdateU2OFilterOpenFlow ¶ added in v1.9.33
func BridgeExists ¶ added in v1.8.3
BridgeExists checks whether the bridge already exists
func CheckAndUpdateHtbQos ¶ added in v1.9.8
func CleanDuplicatePort ¶ added in v1.7.0
func CleanDuplicatePort(ifaceID, portName string)
Find and remove any existing OVS port with this iface-id. Pods can have multiple sandboxes if some are waiting for garbage collection, but only the latest one should have the iface-id set. See: https://github.com/ovn-org/ovn-kubernetes/pull/869
func CleanLostInterface ¶
func CleanLostInterface()
CleanLostInterface will clean up related ovs port, interface and qos When reboot node, the ovs internal interface will be deleted.
func ClearHtbQosQueue ¶ added in v1.9.0
func ClearPodBandwidth ¶
ClearPodBandwidth remove qos related to this pod.
func ClearPortQosBinding ¶ added in v1.9.0
remove qos related to this port.
func ConfigInterfaceMirror ¶ added in v1.8.0
config mirror for interface by pod annotations and install param
func ConstructWaitForNameNotExistsOperation ¶ added in v1.9.6
func ConstructWaitForUniqueOperation ¶ added in v1.9.6
func DeleteAllU2OFilterOpenFlow ¶ added in v1.9.33
func GetInterfacePodNs ¶ added in v1.12.0
func GetLocalnetName ¶ added in v1.11.0
func GetQosList ¶ added in v1.9.0
func GetResidualInternalPorts ¶ added in v1.7.2
func GetResidualInternalPorts() []string
func GetSgPortGroupName ¶ added in v1.8.0
func GetSgV4AssociatedName ¶ added in v1.8.0
func GetSgV6AssociatedName ¶ added in v1.8.0
func IsUserspaceDataPath ¶ added in v1.10.0
func ListExternalIDs ¶ added in v1.12.5
func ListQosQueueIDs ¶ added in v1.12.5
func LogicalRouterPortName ¶ added in v1.9.6
func LogicalSwitchPortName ¶ added in v1.9.6
func PodNameToPortName ¶
PodNameToPortName return the ovn port name for a given pod
func PortExists ¶ added in v1.10.0
PortExists checks whether the port already exists
func SetHtbQosQueueRecord ¶ added in v1.9.0
func SetInterfaceBandwidth ¶ added in v1.7.0
SetInterfaceBandwidth set ingress/egress qos for given pod, annotation values are for node/pod but ingress/egress parameters here are from the point of ovs port/interface view, so reverse input parameters when call func SetInterfaceBandwidth
func SetNetemQos ¶ added in v1.9.0
The latency value expressed in us.
func SetPortTag ¶ added in v1.7.0
func SetQosQueueBinding ¶ added in v1.9.0
func SetQosQueueBinding(podName, podNamespace, ifName, iface, queueUID string, qosIfaceUIDMap map[string]string) error
SetQosQueueBinding set qos related to queue record.
func UpdateOVSVsctlLimiter ¶ added in v1.12.2
func UpdateOVSVsctlLimiter(c int32)
func ValidatePortVendor ¶ added in v1.7.1
ValidatePortVendor returns true if the port's external_ids:vendor=kube-ovn
Types ¶
type ACL ¶ added in v1.12.0
type ACL interface { UpdateIngressACLOps(pgName, asIngressName, asExceptName, protocol string, npp []netv1.NetworkPolicyPort, logEnable bool, namedPortMap map[string]*util.NamedPortInfo) ([]ovsdb.Operation, error) UpdateEgressACLOps(pgName, asEgressName, asExceptName, protocol string, npp []netv1.NetworkPolicyPort, logEnable bool, namedPortMap map[string]*util.NamedPortInfo) ([]ovsdb.Operation, error) CreateGatewayACL(lsName, pgName, gateway string) error CreateNodeACL(pgName, nodeIPStr, joinIPStr string) error CreateSgDenyAllACL(sgName string) error CreateSgBaseACL(sgName, direction string) error UpdateSgACL(sg *kubeovnv1.SecurityGroup, direction string) error UpdateLogicalSwitchACL(lsName string, subnetAcls []kubeovnv1.ACL) error SetACLLog(pgName string, logEnable, isIngress bool) error SetLogicalSwitchPrivate(lsName, cidrBlock, nodeSwitchCIDR string, allowSubnets []string) error SGLostACL(sg *kubeovnv1.SecurityGroup) (bool, error) DeleteAcls(parentName, parentType, direction string, externalIDs map[string]string) error DeleteAclsOps(parentName, parentType, direction string, externalIDs map[string]string) ([]ovsdb.Operation, error) }
type ACLMatch ¶ added in v1.12.1
func NewACLMatch ¶ added in v1.12.1
func NewAndACLMatch ¶ added in v1.12.1
func NewOrACLMatch ¶ added in v1.12.1
type AddressSet ¶ added in v1.12.0
type AddressSet interface { CreateAddressSet(asName string, externalIDs map[string]string) error AddressSetUpdateAddress(asName string, addresses ...string) error DeleteAddressSet(asName string) error DeleteAddressSets(externalIDs map[string]string) error ListAddressSets(externalIDs map[string]string) ([]ovnnb.AddressSet, error) }
type AndACLMatch ¶ added in v1.12.1
type AndACLMatch struct {
// contains filtered or unexported fields
}
func (AndACLMatch) Match ¶ added in v1.12.1
func (m AndACLMatch) Match() (string, error)
Rule generate acl match like 'ip4.src == $test.allow.as && ip4.src != $test.except.as && 12345 <= tcp.dst <= 12500 && outport == @ovn.sg.test_sg && ip'
func (AndACLMatch) String ¶ added in v1.12.1
func (m AndACLMatch) String() string
type Chassis ¶ added in v1.12.1
type Chassis interface { DeleteChassis(chassisName string) error DeleteChassisByHost(node string) error GetAllChassisByHost(nodeName string) (*[]ovnsb.Chassis, error) GetChassisByHost(nodeName string) (*ovnsb.Chassis, error) GetChassis(chassisName string, ignoreNotFound bool) (*ovnsb.Chassis, error) GetKubeOvnChassisses() (*[]ovnsb.Chassis, error) UpdateChassisTag(chassisName, nodeName string) error UpdateChassis(chassis *ovnsb.Chassis, fields ...interface{}) error ListChassis() (*[]ovnsb.Chassis, error) }
type DHCPOptions ¶ added in v1.12.0
type DHCPOptions interface { UpdateDHCPOptions(subnet *kubeovnv1.Subnet, mtu int) (*DHCPOptionsUUIDs, error) DeleteDHCPOptions(lsName, protocol string) error DeleteDHCPOptionsByUUIDs(uuidList ...string) error ListDHCPOptions(needVendorFilter bool, externalIDs map[string]string) ([]ovnnb.DHCPOptions, error) }
type DHCPOptionsUUIDs ¶ added in v1.10.0
type LegacyClient ¶ added in v1.9.5
LegacyClient is the legacy ovn client
func NewLegacyClient ¶ added in v1.9.5
func NewLegacyClient(timeout int) *LegacyClient
NewLegacyClient init a legacy ovn client
func (LegacyClient) DestroyChassis ¶ added in v1.11.0
func (c LegacyClient) DestroyChassis(uuid string) error
func (LegacyClient) DestroyGateways ¶ added in v1.11.0
func (c LegacyClient) DestroyGateways(uuids []string) error
func (LegacyClient) DestroyPortBindings ¶ added in v1.11.15
func (c LegacyClient) DestroyPortBindings(uuids []string) error
func (LegacyClient) DestroyRoutes ¶ added in v1.11.0
func (c LegacyClient) DestroyRoutes(uuids []string) error
func (LegacyClient) DestroyTableWithUUID ¶ added in v1.11.0
func (c LegacyClient) DestroyTableWithUUID(uuid, table string) error
func (LegacyClient) FindUUIDWithAttrInTable ¶ added in v1.11.0
func (c LegacyClient) FindUUIDWithAttrInTable(attribute, value, table string) ([]string, error)
func (LegacyClient) GetAzUUID ¶ added in v1.11.0
func (c LegacyClient) GetAzUUID(az string) (string, error)
func (LegacyClient) GetGatewayUUIDsInOneAZ ¶ added in v1.11.0
func (c LegacyClient) GetGatewayUUIDsInOneAZ(uuid string) ([]string, error)
func (LegacyClient) GetPortBindingUUIDsInOneAZ ¶ added in v1.11.15
func (c LegacyClient) GetPortBindingUUIDsInOneAZ(uuid string) ([]string, error)
func (LegacyClient) GetRouteUUIDsInOneAZ ¶ added in v1.11.0
func (c LegacyClient) GetRouteUUIDsInOneAZ(uuid string) ([]string, error)
func (LegacyClient) GetTs ¶ added in v1.11.15
func (c LegacyClient) GetTs() ([]string, error)
func (LegacyClient) GetTsSubnet ¶ added in v1.9.5
func (c LegacyClient) GetTsSubnet(ts string) (string, error)
type LoadBalancer ¶ added in v1.12.0
type LoadBalancer interface { CreateLoadBalancer(lbName, protocol, selectFields string) error LoadBalancerAddVip(lbName, vip string, backends ...string) error LoadBalancerDeleteVip(lbName, vip string, ignoreHealthCheck bool) error LoadBalancerAddIPPortMapping(lbName, vip string, ipPortMappings map[string]string) error LoadBalancerUpdateIPPortMapping(lbName, vip string, ipPortMappings map[string]string) error LoadBalancerDeleteIPPortMapping(lbName, vip string) error LoadBalancerAddHealthCheck(lbName, vip string, ignoreHealthCheck bool, ipPortMapping, externals map[string]string) error LoadBalancerDeleteHealthCheck(lbName, uuid string) error SetLoadBalancerAffinityTimeout(lbName string, timeout int) error DeleteLoadBalancers(filter func(lb *ovnnb.LoadBalancer) bool) error GetLoadBalancer(lbName string, ignoreNotFound bool) (*ovnnb.LoadBalancer, error) ListLoadBalancers(filter func(lb *ovnnb.LoadBalancer) bool) ([]ovnnb.LoadBalancer, error) LoadBalancerExists(lbName string) (bool, error) }
type LoadBalancerHealthCheck ¶ added in v1.12.2
type LoadBalancerHealthCheck interface { AddLoadBalancerHealthCheck(lbName, vip string, externals map[string]string) error CreateLoadBalancerHealthCheck(lbName, vip string, lbhc *ovnnb.LoadBalancerHealthCheck) error DeleteLoadBalancerHealthCheck(lbName, vip string) error DeleteLoadBalancerHealthChecks(filter func(lbhc *ovnnb.LoadBalancerHealthCheck) bool) error GetLoadBalancerHealthCheck(lbName, vip string, ignoreNotFound bool) (*ovnnb.LoadBalancer, *ovnnb.LoadBalancerHealthCheck, error) ListLoadBalancerHealthChecks(filter func(lbhc *ovnnb.LoadBalancerHealthCheck) bool) ([]ovnnb.LoadBalancerHealthCheck, error) LoadBalancerHealthCheckExists(lbName, vip string) (bool, error) }
type LogicalRouter ¶ added in v1.12.0
type LogicalRouter interface { CreateLogicalRouter(lrName string) error DeleteLogicalRouter(lrName string) error LogicalRouterUpdateLoadBalancers(lrName string, op ovsdb.Mutator, lbNames ...string) error GetLogicalRouter(lrName string, ignoreNotFound bool) (*ovnnb.LogicalRouter, error) ListLogicalRouter(needVendorFilter bool, filter func(lr *ovnnb.LogicalRouter) bool) ([]ovnnb.LogicalRouter, error) LogicalRouterExists(name string) (bool, error) }
type LogicalRouterPolicy ¶ added in v1.12.0
type LogicalRouterPolicy interface { AddLogicalRouterPolicy(lrName string, priority int, match, action string, nextHops []string, externalIDs map[string]string) error DeleteLogicalRouterPolicy(lrName string, priority int, match string) error DeleteLogicalRouterPolicies(lrName string, priority int, externalIDs map[string]string) error DeleteLogicalRouterPolicyByUUID(lrName, uuid string) error DeleteLogicalRouterPolicyByNexthop(lrName string, priority int, nexthop string) error ClearLogicalRouterPolicy(lrName string) error ListLogicalRouterPolicies(lrName string, priority int, externalIDs map[string]string, ignoreExtIDEmptyValue bool) ([]*ovnnb.LogicalRouterPolicy, error) GetLogicalRouterPolicy(lrName string, priority int, match string, ignoreNotFound bool) ([]*ovnnb.LogicalRouterPolicy, error) GetLogicalRouterPoliciesByExtID(lrName, key, value string) ([]*ovnnb.LogicalRouterPolicy, error) }
type LogicalRouterPort ¶ added in v1.12.0
type LogicalRouterPort interface { CreatePeerRouterPort(localRouter, remoteRouter, localRouterPortIP string) error CreateLogicalRouterPort(lrName, lrpName, mac string, networks []string) error UpdateLogicalRouterPortRA(lrpName, ipv6RAConfigsStr string, enableIPv6RA bool) error UpdateLogicalRouterPortOptions(lrpName string, options map[string]string) error DeleteLogicalRouterPort(lrpName string) error DeleteLogicalRouterPorts(externalIDs map[string]string, filter func(lrp *ovnnb.LogicalRouterPort) bool) error GetLogicalRouterPort(lrpName string, ignoreNotFound bool) (*ovnnb.LogicalRouterPort, error) GetLogicalRouterPortByUUID(uuid string) (*ovnnb.LogicalRouterPort, error) ListLogicalRouterPorts(externalIDs map[string]string, filter func(lrp *ovnnb.LogicalRouterPort) bool) ([]ovnnb.LogicalRouterPort, error) LogicalRouterPortExists(lrpName string) (bool, error) }
type LogicalRouterStaticRoute ¶ added in v1.12.0
type LogicalRouterStaticRoute interface { AddLogicalRouterStaticRoute(lrName, routeTable, policy, ipPrefix string, bfdID *string, nexthops ...string) error ClearLogicalRouterStaticRoute(lrName string) error DeleteLogicalRouterStaticRoute(lrName string, routeTable, policy *string, ipPrefix, nextHop string) error ListLogicalRouterStaticRoutesByOption(lrName, routeTable, key, value string) ([]*ovnnb.LogicalRouterStaticRoute, error) ListLogicalRouterStaticRoutes(lrName string, routeTable, policy *string, ipPrefix string, externalIDs map[string]string) ([]*ovnnb.LogicalRouterStaticRoute, error) LogicalRouterStaticRouteExists(lrName, routeTable, policy, ipPrefix, nexthop string) (bool, error) }
type LogicalSwitch ¶ added in v1.12.0
type LogicalSwitch interface { CreateLogicalSwitch(lsName, lrName, cidrBlock, gateway string, needRouter, randomAllocateGW bool) error CreateBareLogicalSwitch(lsName string) error LogicalSwitchUpdateLoadBalancers(lsName string, op ovsdb.Mutator, lbNames ...string) error LogicalSwitchUpdateOtherConfig(lsName string, op ovsdb.Mutator, otherConfig map[string]string) error DeleteLogicalSwitch(lsName string) error ListLogicalSwitch(needVendorFilter bool, filter func(ls *ovnnb.LogicalSwitch) bool) ([]ovnnb.LogicalSwitch, error) LogicalSwitchExists(lsName string) (bool, error) }
type LogicalSwitchPort ¶ added in v1.12.0
type LogicalSwitchPort interface { CreateLogicalSwitchPort(lsName, lspName, ip, mac, podName, namespace string, portSecurity bool, securityGroups, vips string, enableDHCP bool, dhcpOptions *DHCPOptionsUUIDs, vpc string) error CreateBareLogicalSwitchPort(lsName, lspName, ip, mac string) error CreateLocalnetLogicalSwitchPort(lsName, lspName, provider, cidrBlock string, vlanID int) error CreateVirtualLogicalSwitchPorts(lsName string, ips ...string) error SetLogicalSwitchPortSecurity(portSecurity bool, lspName, mac, ips, vips string) error SetLogicalSwitchPortVirtualParents(lsName, parents string, ips ...string) error SetLogicalSwitchPortArpProxy(lspName string, enableArpProxy bool) error SetLogicalSwitchPortExternalIDs(lspName string, externalIDs map[string]string) error SetLogicalSwitchPortVlanTag(lspName string, vlanID int) error SetLogicalSwitchPortsSecurityGroup(sgName, op string) error EnablePortLayer2forward(lspName string) error DeleteLogicalSwitchPort(lspName string) error DeleteLogicalSwitchPorts(externalIDs map[string]string, filter func(lsp *ovnnb.LogicalSwitchPort) bool) error ListLogicalSwitchPorts(needVendorFilter bool, externalIDs map[string]string, filter func(lsp *ovnnb.LogicalSwitchPort) bool) ([]ovnnb.LogicalSwitchPort, error) ListNormalLogicalSwitchPorts(needVendorFilter bool, externalIDs map[string]string) ([]ovnnb.LogicalSwitchPort, error) ListLogicalSwitchPortsWithLegacyExternalIDs() ([]ovnnb.LogicalSwitchPort, error) GetLogicalSwitchPort(lspName string, ignoreNotFound bool) (*ovnnb.LogicalSwitchPort, error) LogicalSwitchPortExists(name string) (bool, error) }
type NAT ¶ added in v1.12.0
type NAT interface { GetNATByUUID(uuid string) (*ovnnb.NAT, error) AddNat(lrName, natType, externalIP, logicalIP, logicalMac, port string, options map[string]string) error UpdateSnat(lrName, externalIP, logicalIP string) error UpdateDnatAndSnat(lrName, externalIP, logicalIP, lspName, externalMac, gatewayType string) error DeleteNats(lrName, natType, logicalIP string) error DeleteNat(lrName, natType, externalIP, logicalIP string) error NatExists(lrName, natType, externalIP, logicalIP string) (bool, error) ListNats(lrName, natType, logicalIP string, externalIDs map[string]string) ([]*ovnnb.NAT, error) }
type NBGlobal ¶ added in v1.12.0
type NBGlobal interface { UpdateNbGlobal(nbGlobal *ovnnb.NBGlobal, fields ...interface{}) error SetAzName(azName string) error SetUseCtInvMatch() error SetICAutoRoute(enable bool, blackList []string) error SetLsDnatModDlDst(enabled bool) error SetLsCtSkipDstLportIPs(enabled bool) error GetNbGlobal() (*ovnnb.NBGlobal, error) }
type NbClient ¶ added in v1.12.1
type NbClient interface { ACL AddressSet BFD DHCPOptions LoadBalancer LoadBalancerHealthCheck LogicalRouterPolicy LogicalRouterPort LogicalRouterStaticRoute LogicalRouter LogicalSwitchPort LogicalSwitch NAT NBGlobal PortGroup CreateGatewayLogicalSwitch(lsName, lrName, provider, ip, mac string, vlanID int, chassises ...string) error CreateLogicalPatchPort(lsName, lrName, lspName, lrpName, ip, mac string, chassises ...string) error RemoveLogicalPatchPort(lspName, lrpName string) error DeleteLogicalGatewaySwitch(lsName, lrName string) error DeleteSecurityGroup(sgName string) error Common }
type OVNNbClient ¶ added in v1.12.1
type OVNNbClient struct { ClusterRouter string // contains filtered or unexported fields }
func NewOvnNbClient ¶ added in v1.12.1
func NewOvnNbClient(ovnNbAddr string, ovnNbTimeout int) (*OVNNbClient, error)
func (*OVNNbClient) ACLExists ¶ added in v1.12.1
func (c *OVNNbClient) ACLExists(parent, direction, priority, match string) (bool, error)
func (*OVNNbClient) AddLoadBalancerHealthCheck ¶ added in v1.12.2
func (c *OVNNbClient) AddLoadBalancerHealthCheck(lbName, vipEndpoint string, externals map[string]string) error
func (*OVNNbClient) AddLogicalRouterPolicy ¶ added in v1.12.1
func (c *OVNNbClient) AddLogicalRouterPolicy(lrName string, priority int, match, action string, nextHops []string, externalIDs map[string]string) error
AddLogicalRouterPolicy add a policy route to logical router
func (*OVNNbClient) AddLogicalRouterPort ¶ added in v1.12.1
func (c *OVNNbClient) AddLogicalRouterPort(lr, name, mac, networks string) error
func (*OVNNbClient) AddLogicalRouterStaticRoute ¶ added in v1.12.1
func (c *OVNNbClient) AddLogicalRouterStaticRoute(lrName, routeTable, policy, ipPrefix string, bfdID *string, nexthops ...string) error
AddLogicalRouterStaticRoute add a logical router static route
func (*OVNNbClient) AddNat ¶ added in v1.12.1
func (c *OVNNbClient) AddNat(lrName, natType, externalIP, logicalIP, logicalMac, port string, options map[string]string) error
func (*OVNNbClient) AddressSetExists ¶ added in v1.12.1
func (c *OVNNbClient) AddressSetExists(name string) (bool, error)
func (*OVNNbClient) AddressSetUpdateAddress ¶ added in v1.12.1
func (c *OVNNbClient) AddressSetUpdateAddress(asName string, addresses ...string) error
AddressSetUpdateAddress update addresses, clear addresses when addresses is empty
func (*OVNNbClient) ClearLogicalRouterPolicy ¶ added in v1.12.1
func (c *OVNNbClient) ClearLogicalRouterPolicy(lrName string) error
ClearLogicalRouterPolicy clear policy from logical router once
func (*OVNNbClient) ClearLogicalRouterStaticRoute ¶ added in v1.12.1
func (c *OVNNbClient) ClearLogicalRouterStaticRoute(lrName string) error
ClearLogicalRouterStaticRoute clear static route from logical router once
func (*OVNNbClient) CreateAcls ¶ added in v1.12.1
func (c *OVNNbClient) CreateAcls(parentName, parentType string, acls ...*ovnnb.ACL) error
CreateAcls create several acl once parentType is 'ls' or 'pg'
func (*OVNNbClient) CreateAclsOps ¶ added in v1.12.1
func (c *OVNNbClient) CreateAclsOps(parentName, parentType string, acls ...*ovnnb.ACL) ([]ovsdb.Operation, error)
CreateAcls return operations which create several acl once parentType is 'ls' or 'pg'
func (*OVNNbClient) CreateAddressSet ¶ added in v1.12.1
func (c *OVNNbClient) CreateAddressSet(asName string, externalIDs map[string]string) error
CreateAddressSet create address set with external ids
func (*OVNNbClient) CreateBareACL ¶ added in v1.12.1
func (c *OVNNbClient) CreateBareACL(parentName, direction, priority, match, action string) error
func (*OVNNbClient) CreateBareLogicalSwitch ¶ added in v1.12.1
func (c *OVNNbClient) CreateBareLogicalSwitch(lsName string) error
CreateBareLogicalSwitch create logical switch with basic configuration
func (*OVNNbClient) CreateBareLogicalSwitchPort ¶ added in v1.12.1
func (c *OVNNbClient) CreateBareLogicalSwitchPort(lsName, lspName, ip, mac string) error
CreateBareLogicalSwitchPort create logical switch port with basic configuration
func (*OVNNbClient) CreateDHCPOptions ¶ added in v1.12.1
func (c *OVNNbClient) CreateDHCPOptions(lsName, cidr, options string) error
func (*OVNNbClient) CreateGatewayACL ¶ added in v1.12.1
func (c *OVNNbClient) CreateGatewayACL(lsName, pgName, gateway string) error
CreateGatewayACL create allow acl for subnet gateway
func (*OVNNbClient) CreateGatewayChassises ¶ added in v1.12.1
func (c *OVNNbClient) CreateGatewayChassises(lrpName string, chassises ...string) error
CreateGatewayChassises create multiple gateway chassis once
func (*OVNNbClient) CreateGatewayChassisesOp ¶ added in v1.12.1
func (c *OVNNbClient) CreateGatewayChassisesOp(lrpName string, chassises []string) ([]ovsdb.Operation, error)
DeleteGatewayChassisOp create operation which create gateway chassis
func (*OVNNbClient) CreateGatewayLogicalSwitch ¶ added in v1.12.1
func (c *OVNNbClient) CreateGatewayLogicalSwitch(lsName, lrName, provider, ip, mac string, vlanID int, chassises ...string) error
CreateGatewayLogicalSwitch create gateway switch connect external networks
func (*OVNNbClient) CreateLoadBalancer ¶ added in v1.12.1
func (c *OVNNbClient) CreateLoadBalancer(lbName, protocol, selectFields string) error
CreateLoadBalancer create loadbalancer
func (*OVNNbClient) CreateLoadBalancerHealthCheck ¶ added in v1.12.2
func (c *OVNNbClient) CreateLoadBalancerHealthCheck(lbName, vipEndpoint string, lbhc *ovnnb.LoadBalancerHealthCheck) error
CreateLoadBalancerHealthCheck create lb health check
func (*OVNNbClient) CreateLocalnetLogicalSwitchPort ¶ added in v1.12.1
func (c *OVNNbClient) CreateLocalnetLogicalSwitchPort(lsName, lspName, provider, cidrBlock string, vlanID int) error
CreateLocalnetLogicalSwitchPort create localnet type logical switch port
func (*OVNNbClient) CreateLogicalPatchPort ¶ added in v1.12.1
func (c *OVNNbClient) CreateLogicalPatchPort(lsName, lrName, lspName, lrpName, ip, mac string, chassises ...string) error
CreateLogicalPatchPort create logical router port and associated logical switch port which type is router
func (*OVNNbClient) CreateLogicalRouter ¶ added in v1.12.1
func (c *OVNNbClient) CreateLogicalRouter(lrName string) error
CreateLogicalRouter create logical router in ovn
func (*OVNNbClient) CreateLogicalRouterPolicies ¶ added in v1.12.1
func (c *OVNNbClient) CreateLogicalRouterPolicies(lrName string, policies ...*ovnnb.LogicalRouterPolicy) error
CreateLogicalRouterPolicies create several logical router policy once
func (*OVNNbClient) CreateLogicalRouterPort ¶ added in v1.12.1
func (c *OVNNbClient) CreateLogicalRouterPort(lrName, lrpName, mac string, networks []string) error
CreateLogicalRouterPort create logical router port with basic configuration
func (*OVNNbClient) CreateLogicalRouterPortOp ¶ added in v1.12.1
func (c *OVNNbClient) CreateLogicalRouterPortOp(lrp *ovnnb.LogicalRouterPort, lrName string) ([]ovsdb.Operation, error)
CreateLogicalRouterPortOp create operation which create logical router port
func (*OVNNbClient) CreateLogicalRouterStaticRoutes ¶ added in v1.12.1
func (c *OVNNbClient) CreateLogicalRouterStaticRoutes(lrName string, routes ...*ovnnb.LogicalRouterStaticRoute) error
CreateLogicalRouterStaticRoutes create several logical router static route once
func (*OVNNbClient) CreateLogicalSwitch ¶ added in v1.12.1
func (c *OVNNbClient) CreateLogicalSwitch(lsName, lrName, cidrBlock, gateway string, needRouter, randomAllocateGW bool) error
CreateLogicalSwitch create logical switch
func (*OVNNbClient) CreateLogicalSwitchPort ¶ added in v1.12.1
func (c *OVNNbClient) CreateLogicalSwitchPort(lsName, lspName, ip, mac, podName, namespace string, portSecurity bool, securityGroups, vips string, enableDHCP bool, dhcpOptions *DHCPOptionsUUIDs, vpc string) error
func (*OVNNbClient) CreateLogicalSwitchPortOp ¶ added in v1.12.1
func (c *OVNNbClient) CreateLogicalSwitchPortOp(lsp *ovnnb.LogicalSwitchPort, lsName string) ([]ovsdb.Operation, error)
CreateLogicalSwitchPortOp create operations which create logical switch port
func (*OVNNbClient) CreateNats ¶ added in v1.12.1
func (c *OVNNbClient) CreateNats(lrName string, nats ...*ovnnb.NAT) error
CreateNats create several logical router nat rule once
func (*OVNNbClient) CreateNbGlobal ¶ added in v1.12.1
func (c *OVNNbClient) CreateNbGlobal(nbGlobal *ovnnb.NBGlobal) error
func (*OVNNbClient) CreateNodeACL ¶ added in v1.12.1
func (c *OVNNbClient) CreateNodeACL(pgName, nodeIPStr, joinIPStr string) error
CreateNodeACL create allow acl for node join ip
func (*OVNNbClient) CreatePeerRouterPort ¶ added in v1.12.1
func (c *OVNNbClient) CreatePeerRouterPort(localRouter, remoteRouter, localRouterPortIP string) error
func (*OVNNbClient) CreatePortGroup ¶ added in v1.12.1
func (c *OVNNbClient) CreatePortGroup(pgName string, externalIDs map[string]string) error
func (*OVNNbClient) CreateRouterPortOp ¶ added in v1.12.1
func (c *OVNNbClient) CreateRouterPortOp(lsName, lrName, lspName, lrpName, ip, mac string) ([]ovsdb.Operation, error)
func (*OVNNbClient) CreateSgBaseACL ¶ added in v1.12.1
func (c *OVNNbClient) CreateSgBaseACL(sgName, direction string) error
func (*OVNNbClient) CreateSgDenyAllACL ¶ added in v1.12.1
func (c *OVNNbClient) CreateSgDenyAllACL(sgName string) error
func (*OVNNbClient) CreateVirtualLogicalSwitchPorts ¶ added in v1.12.1
func (c *OVNNbClient) CreateVirtualLogicalSwitchPorts(lsName string, ips ...string) error
CreateVirtualLogicalSwitchPorts create several virtual type logical switch port once
func (*OVNNbClient) DHCPOptionsExists ¶ added in v1.12.1
func (c *OVNNbClient) DHCPOptionsExists(lsName, cidr string) (bool, error)
func (*OVNNbClient) DeleteACL ¶ added in v1.12.1
func (c *OVNNbClient) DeleteACL(parentName, parentType, direction, priority, match string) error
func (*OVNNbClient) DeleteAcls ¶ added in v1.12.1
func (c *OVNNbClient) DeleteAcls(parentName, parentType, direction string, externalIDs map[string]string) error
DeleteAcls delete several acl once, delete to-lport and from-lport direction acl when direction is empty, otherwise one-way parentType is 'ls' or 'pg'
func (*OVNNbClient) DeleteAclsOps ¶ added in v1.12.1
func (c *OVNNbClient) DeleteAclsOps(parentName, parentType, direction string, externalIDs map[string]string) ([]ovsdb.Operation, error)
DeleteAcls return operation which delete several acl once, delete to-lport and from-lport direction acl when direction is empty, otherwise one-way parentType is 'ls' or 'pg'
func (*OVNNbClient) DeleteAddressSet ¶ added in v1.12.1
func (c *OVNNbClient) DeleteAddressSet(asName string) error
func (*OVNNbClient) DeleteAddressSets ¶ added in v1.12.1
func (c *OVNNbClient) DeleteAddressSets(externalIDs map[string]string) error
DeleteAddressSets delete several address set once
func (*OVNNbClient) DeleteBFD ¶ added in v1.12.1
func (c *OVNNbClient) DeleteBFD(lrpName, dstIP string) error
func (*OVNNbClient) DeleteDHCPOptions ¶ added in v1.12.1
func (c *OVNNbClient) DeleteDHCPOptions(lsName, protocol string) error
DeleteDHCPOptions delete dhcp options which belongs to logical switch
func (*OVNNbClient) DeleteDHCPOptionsByUUIDs ¶ added in v1.12.1
func (c *OVNNbClient) DeleteDHCPOptionsByUUIDs(uuidList ...string) error
DeleteDHCPOptionsByUUIDs delete dhcp options by uuid
func (*OVNNbClient) DeleteGatewayChassisOp ¶ added in v1.12.1
func (c *OVNNbClient) DeleteGatewayChassisOp(chassisName string) ([]ovsdb.Operation, error)
DeleteGatewayChassisOp create operation which delete gateway chassis
func (*OVNNbClient) DeleteGatewayChassises ¶ added in v1.12.1
func (c *OVNNbClient) DeleteGatewayChassises(lrpName string, chassises []string) error
DeleteGatewayChassises delete multiple gateway chassis once
func (*OVNNbClient) DeleteLoadBalancer ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLoadBalancer(lbName string) error
DeleteLoadBalancer delete loadbalancer
func (*OVNNbClient) DeleteLoadBalancerHealthCheck ¶ added in v1.12.2
func (c *OVNNbClient) DeleteLoadBalancerHealthCheck(lbName, vip string) error
DeleteLoadBalancerHealthCheck delete lb health check
func (*OVNNbClient) DeleteLoadBalancerHealthCheckOp ¶ added in v1.12.2
func (c *OVNNbClient) DeleteLoadBalancerHealthCheckOp(lbName, vip string) ([]ovsdb.Operation, error)
DeleteLoadBalancerHealthCheckOp delete operation which delete lb health check
func (*OVNNbClient) DeleteLoadBalancerHealthChecks ¶ added in v1.12.2
func (c *OVNNbClient) DeleteLoadBalancerHealthChecks(filter func(lb *ovnnb.LoadBalancerHealthCheck) bool) error
DeleteLoadBalancerHealthChecks delete several lb health checks once
func (*OVNNbClient) DeleteLoadBalancerOp ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLoadBalancerOp(lbName string) ([]ovsdb.Operation, error)
DeleteLoadBalancerOp create operation which delete load balancer
func (*OVNNbClient) DeleteLoadBalancers ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLoadBalancers(filter func(lb *ovnnb.LoadBalancer) bool) error
DeleteLoadBalancers delete several loadbalancer once
func (*OVNNbClient) DeleteLogicalGatewaySwitch ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLogicalGatewaySwitch(lsName, lrName string) error
DeleteLogicalGatewaySwitch delete gateway switch and corresponding port
func (*OVNNbClient) DeleteLogicalRouter ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLogicalRouter(lrName string) error
DeleteLogicalRouter delete logical router in ovn
func (*OVNNbClient) DeleteLogicalRouterPolicies ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLogicalRouterPolicies(lrName string, priority int, externalIDs map[string]string) error
DeleteLogicalRouterPolicy delete some policies from logical router once
func (*OVNNbClient) DeleteLogicalRouterPolicy ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLogicalRouterPolicy(lrName string, priority int, match string) error
DeleteLogicalRouterPolicy delete policy from logical router
func (*OVNNbClient) DeleteLogicalRouterPolicyByNexthop ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLogicalRouterPolicyByNexthop(lrName string, priority int, nexthop string) error
func (*OVNNbClient) DeleteLogicalRouterPolicyByUUID ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLogicalRouterPolicyByUUID(lrName, uuid string) error
func (*OVNNbClient) DeleteLogicalRouterPort ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLogicalRouterPort(lrpName string) error
DeleteLogicalRouterPort delete logical router port from logical router
func (*OVNNbClient) DeleteLogicalRouterPortOp ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLogicalRouterPortOp(lrpName string) ([]ovsdb.Operation, error)
DeleteLogicalRouterPortOp create operation which delete logical router port
func (*OVNNbClient) DeleteLogicalRouterPorts ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLogicalRouterPorts(externalIDs map[string]string, filter func(lrp *ovnnb.LogicalRouterPort) bool) error
DeleteLogicalRouterPort delete logical router port from logical router
func (*OVNNbClient) DeleteLogicalRouterStaticRoute ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLogicalRouterStaticRoute(lrName string, routeTable, policy *string, ipPrefix, nexthop string) error
DeleteLogicalRouterStaticRoute add a logical router static route
func (*OVNNbClient) DeleteLogicalSwitch ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLogicalSwitch(lsName string) error
DeleteLogicalSwitch delete logical switch
func (*OVNNbClient) DeleteLogicalSwitchOp ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLogicalSwitchOp(lsName string) ([]ovsdb.Operation, error)
DeleteLogicalSwitchOp create operations that delete logical switch
func (*OVNNbClient) DeleteLogicalSwitchPort ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLogicalSwitchPort(lspName string) error
DeleteLogicalSwitchPort delete logical switch port in ovn
func (*OVNNbClient) DeleteLogicalSwitchPortOp ¶ added in v1.12.1
func (c *OVNNbClient) DeleteLogicalSwitchPortOp(lspName string) ([]ovsdb.Operation, error)
DeleteLogicalSwitchPortOp create operations which delete logical switch port
func (*OVNNbClient) DeleteLogicalSwitchPorts ¶ added in v1.12.4
func (c *OVNNbClient) DeleteLogicalSwitchPorts(externalIDs map[string]string, filter func(lrp *ovnnb.LogicalSwitchPort) bool) error
DeleteLogicalSwitchPorts delete logical switch port from logical switch
func (*OVNNbClient) DeleteNat ¶ added in v1.12.1
func (c *OVNNbClient) DeleteNat(lrName, natType, externalIP, logicalIP string) error
DeleteNat delete nat rule
func (*OVNNbClient) DeleteNats ¶ added in v1.12.1
func (c *OVNNbClient) DeleteNats(lrName, natType, logicalIP string) error
DeleteNat delete several nat rule once
func (*OVNNbClient) DeleteNbGlobal ¶ added in v1.12.1
func (c *OVNNbClient) DeleteNbGlobal() error
func (*OVNNbClient) DeletePortGroup ¶ added in v1.12.1
func (c *OVNNbClient) DeletePortGroup(pgName string) error
func (*OVNNbClient) DeleteRouterPolicy ¶ added in v1.12.1
func (c *OVNNbClient) DeleteRouterPolicy(lr *ovnnb.LogicalRouter, uuid string) error
func (*OVNNbClient) DeleteSecurityGroup ¶ added in v1.12.1
func (c *OVNNbClient) DeleteSecurityGroup(sgName string) error
func (*OVNNbClient) EnablePortLayer2forward ¶ added in v1.12.1
func (c *OVNNbClient) EnablePortLayer2forward(lspName string) error
EnablePortLayer2forward set logical switch port addresses as 'unknown'
func (*OVNNbClient) GatewayChassisExist ¶ added in v1.12.1
func (c *OVNNbClient) GatewayChassisExist(name string) (bool, error)
func (*OVNNbClient) GetACL ¶ added in v1.12.1
func (c *OVNNbClient) GetACL(parent, direction, priority, match string, ignoreNotFound bool) (*ovnnb.ACL, error)
GetACL get acl by direction, priority and match, be consistent with ovn-nbctl which direction, priority and match determine one acl in port group or logical switch
func (*OVNNbClient) GetAddressSet ¶ added in v1.12.1
func (c *OVNNbClient) GetAddressSet(asName string, ignoreNotFound bool) (*ovnnb.AddressSet, error)
GetAddressSet get address set by name
func (*OVNNbClient) GetDHCPOptions ¶ added in v1.12.1
func (c *OVNNbClient) GetDHCPOptions(lsName, protocol string, ignoreNotFound bool) (*ovnnb.DHCPOptions, error)
GetDHCPOptions get dhcp options, a dhcp options is uniquely identified by switch(lsName) and protocol
func (*OVNNbClient) GetEntityInfo ¶ added in v1.12.1
func (c *OVNNbClient) GetEntityInfo(entity interface{}) error
GetEntityInfo get entity info by column which is the index, reference to ovn-nb.ovsschema(ovsdb-client get-schema unix:/var/run/ovn/ovnnb_db.sock OVN_Northbound) for more information, UUID is index
func (*OVNNbClient) GetGatewayChassis ¶ added in v1.12.1
func (c *OVNNbClient) GetGatewayChassis(name string, ignoreNotFound bool) (*ovnnb.GatewayChassis, error)
GetGatewayChassis get gateway chassis by name
func (*OVNNbClient) GetLoadBalancer ¶ added in v1.12.1
func (c *OVNNbClient) GetLoadBalancer(lbName string, ignoreNotFound bool) (*ovnnb.LoadBalancer, error)
GetLoadBalancer get load balancer by name, it is because of lack name index that does't use OVNNbClient.Get
func (*OVNNbClient) GetLoadBalancerHealthCheck ¶ added in v1.12.2
func (c *OVNNbClient) GetLoadBalancerHealthCheck(lbName, vipEndpoint string, ignoreNotFound bool) (*ovnnb.LoadBalancer, *ovnnb.LoadBalancerHealthCheck, error)
GetLoadBalancerHealthCheck get lb health check by vip
func (*OVNNbClient) GetLogicalRouter ¶ added in v1.12.1
func (c *OVNNbClient) GetLogicalRouter(lrName string, ignoreNotFound bool) (*ovnnb.LogicalRouter, error)
GetLogicalRouter get logical router by name, it is because of lack name index that does't use OVNNbClient.Get
func (*OVNNbClient) GetLogicalRouterPoliciesByExtID ¶ added in v1.12.1
func (c *OVNNbClient) GetLogicalRouterPoliciesByExtID(lrName, key, value string) ([]*ovnnb.LogicalRouterPolicy, error)
GetLogicalRouterPoliciesByExtID get logical router policy route by external ID
func (*OVNNbClient) GetLogicalRouterPolicy ¶ added in v1.12.1
func (c *OVNNbClient) GetLogicalRouterPolicy(lrName string, priority int, match string, ignoreNotFound bool) ([]*ovnnb.LogicalRouterPolicy, error)
GetLogicalRouterPolicy get logical router policy by priority and match, be consistent with ovn-nbctl which priority and match determine one policy in logical router
func (*OVNNbClient) GetLogicalRouterPolicyByUUID ¶ added in v1.12.1
func (c *OVNNbClient) GetLogicalRouterPolicyByUUID(uuid string) (*ovnnb.LogicalRouterPolicy, error)
GetLogicalRouterPolicyByUUID get logical router policy by UUID
func (*OVNNbClient) GetLogicalRouterPort ¶ added in v1.12.1
func (c *OVNNbClient) GetLogicalRouterPort(lrpName string, ignoreNotFound bool) (*ovnnb.LogicalRouterPort, error)
GetLogicalRouterPort get logical router port by name
func (*OVNNbClient) GetLogicalRouterPortByUUID ¶ added in v1.12.1
func (c *OVNNbClient) GetLogicalRouterPortByUUID(uuid string) (*ovnnb.LogicalRouterPort, error)
GetLogicalRouterPortByUUID get logical router port by UUID
func (*OVNNbClient) GetLogicalRouterStaticRoute ¶ added in v1.12.1
func (c *OVNNbClient) GetLogicalRouterStaticRoute(lrName, routeTable, policy, ipPrefix, nexthop string, ignoreNotFound bool) (*ovnnb.LogicalRouterStaticRoute, error)
GetLogicalRouterStaticRoute get logical router static route by some attribute, a static route is uniquely identified by router(lrName), policy and ipPrefix when route is not ecmp a static route is uniquely identified by router(lrName), policy, ipPrefix and nexthop when route is ecmp
func (*OVNNbClient) GetLogicalRouterStaticRouteByUUID ¶ added in v1.12.1
func (c *OVNNbClient) GetLogicalRouterStaticRouteByUUID(uuid string) (*ovnnb.LogicalRouterStaticRoute, error)
GetLogicalRouterStaticRouteByUUID get logical router static route by UUID
func (*OVNNbClient) GetLogicalSwitch ¶ added in v1.12.1
func (c *OVNNbClient) GetLogicalSwitch(lsName string, ignoreNotFound bool) (*ovnnb.LogicalSwitch, error)
GetLogicalSwitch get logical switch by name, it is because of lack name index that does't use OVNNbClient.Get
func (*OVNNbClient) GetLogicalSwitchPort ¶ added in v1.12.1
func (c *OVNNbClient) GetLogicalSwitchPort(lspName string, ignoreNotFound bool) (*ovnnb.LogicalSwitchPort, error)
GetLogicalSwitchPort get logical switch port by name
func (*OVNNbClient) GetNATByUUID ¶ added in v1.12.1
func (c *OVNNbClient) GetNATByUUID(uuid string) (*ovnnb.NAT, error)
GetNATByUUID get NAT by UUID
func (*OVNNbClient) GetNat ¶ added in v1.12.1
func (c *OVNNbClient) GetNat(lrName, natType, externalIP, logicalIP string, ignoreNotFound bool) (*ovnnb.NAT, error)
GetNat get nat by some attribute, a nat rule is uniquely identified by router(lrName), type(natType) and logical_ip when snat a nat rule is uniquely identified by router(lrName), type(natType) and external_ip when dnat_and_snat
func (*OVNNbClient) GetNbGlobal ¶ added in v1.12.1
func (c *OVNNbClient) GetNbGlobal() (*ovnnb.NBGlobal, error)
func (*OVNNbClient) GetPortGroup ¶ added in v1.12.1
GetPortGroup get port group by name
func (*OVNNbClient) ListAcls ¶ added in v1.12.1
func (c *OVNNbClient) ListAcls(direction string, externalIDs map[string]string) ([]ovnnb.ACL, error)
ListAcls list acls which match the given externalIDs, result should include all to-lport and from-lport acls when direction is empty, result should include all acls when externalIDs is empty, result should include all acls which externalIDs[key] is not empty when externalIDs[key] is "" TODO: maybe add other filter conditions(priority or match)
func (*OVNNbClient) ListAddressSets ¶ added in v1.12.1
func (c *OVNNbClient) ListAddressSets(externalIDs map[string]string) ([]ovnnb.AddressSet, error)
ListAddressSets list address set by external_ids
func (*OVNNbClient) ListBFD ¶ added in v1.12.1
func (c *OVNNbClient) ListBFD(lrpName, dstIP string) ([]ovnnb.BFD, error)
func (*OVNNbClient) ListDHCPOptions ¶ added in v1.12.1
func (c *OVNNbClient) ListDHCPOptions(needVendorFilter bool, externalIDs map[string]string) ([]ovnnb.DHCPOptions, error)
ListDHCPOptions list dhcp options which match the given externalIDs
func (*OVNNbClient) ListLoadBalancerHealthChecks ¶ added in v1.12.2
func (c *OVNNbClient) ListLoadBalancerHealthChecks(filter func(lbhc *ovnnb.LoadBalancerHealthCheck) bool) ([]ovnnb.LoadBalancerHealthCheck, error)
ListLoadBalancerHealthChecks list all lb health checks
func (*OVNNbClient) ListLoadBalancers ¶ added in v1.12.1
func (c *OVNNbClient) ListLoadBalancers(filter func(lb *ovnnb.LoadBalancer) bool) ([]ovnnb.LoadBalancer, error)
ListLoadBalancers list all load balancers
func (*OVNNbClient) ListLogicalRouter ¶ added in v1.12.1
func (c *OVNNbClient) ListLogicalRouter(needVendorFilter bool, filter func(lr *ovnnb.LogicalRouter) bool) ([]ovnnb.LogicalRouter, error)
ListLogicalRouter list logical router
func (*OVNNbClient) ListLogicalRouterPolicies ¶ added in v1.12.1
func (c *OVNNbClient) ListLogicalRouterPolicies(lrName string, priority int, externalIDs map[string]string, ignoreExtIDEmptyValue bool) ([]*ovnnb.LogicalRouterPolicy, error)
ListLogicalRouterPolicies list route policy which match the given externalIDs
func (*OVNNbClient) ListLogicalRouterPorts ¶ added in v1.12.1
func (c *OVNNbClient) ListLogicalRouterPorts(externalIDs map[string]string, filter func(lrp *ovnnb.LogicalRouterPort) bool) ([]ovnnb.LogicalRouterPort, error)
ListLogicalRouterPorts list logical router ports
func (*OVNNbClient) ListLogicalRouterStaticRoutes ¶ added in v1.12.1
func (c *OVNNbClient) ListLogicalRouterStaticRoutes(lrName string, routeTable, policy *string, ipPrefix string, externalIDs map[string]string) ([]*ovnnb.LogicalRouterStaticRoute, error)
ListLogicalRouterStaticRoutes list route which match the given externalIDs
func (*OVNNbClient) ListLogicalRouterStaticRoutesByOption ¶ added in v1.12.1
func (c *OVNNbClient) ListLogicalRouterStaticRoutesByOption(lrName, _, key, value string) ([]*ovnnb.LogicalRouterStaticRoute, error)
func (*OVNNbClient) ListLogicalSwitch ¶ added in v1.12.1
func (c *OVNNbClient) ListLogicalSwitch(needVendorFilter bool, filter func(ls *ovnnb.LogicalSwitch) bool) ([]ovnnb.LogicalSwitch, error)
ListLogicalSwitch list logical switch
func (*OVNNbClient) ListLogicalSwitchPorts ¶ added in v1.12.1
func (c *OVNNbClient) ListLogicalSwitchPorts(needVendorFilter bool, externalIDs map[string]string, filter func(lsp *ovnnb.LogicalSwitchPort) bool) ([]ovnnb.LogicalSwitchPort, error)
ListLogicalSwitchPorts list logical switch ports
func (*OVNNbClient) ListLogicalSwitchPortsWithLegacyExternalIDs ¶ added in v1.12.1
func (c *OVNNbClient) ListLogicalSwitchPortsWithLegacyExternalIDs() ([]ovnnb.LogicalSwitchPort, error)
ListLogicalSwitchPortsWithLegacyExternalIDs list logical switch ports with legacy external-ids
func (*OVNNbClient) ListNats ¶ added in v1.12.1
func (c *OVNNbClient) ListNats(lrName, natType, logicalIP string, externalIDs map[string]string) ([]*ovnnb.NAT, error)
ListNats list acls which match the given externalIDs
func (*OVNNbClient) ListNormalLogicalSwitchPorts ¶ added in v1.12.1
func (c *OVNNbClient) ListNormalLogicalSwitchPorts(needVendorFilter bool, externalIDs map[string]string) ([]ovnnb.LogicalSwitchPort, error)
ListNormalLogicalSwitchPorts list logical switch ports which type is ""
func (*OVNNbClient) ListPortGroups ¶ added in v1.12.1
ListPortGroups list port groups which match the given externalIDs, result should include all port groups when externalIDs is empty, result should include all port groups which externalIDs[key] is not empty when externalIDs[key] is ""
func (*OVNNbClient) LoadBalancerAddHealthCheck ¶ added in v1.12.2
func (c *OVNNbClient) LoadBalancerAddHealthCheck(lbName, vipEndpoint string, ignoreHealthCheck bool, ipPortMapping, externals map[string]string) error
LoadBalancerAddHealthCheck adds health check
func (*OVNNbClient) LoadBalancerAddIPPortMapping ¶ added in v1.12.2
func (c *OVNNbClient) LoadBalancerAddIPPortMapping(lbName, vipEndpoint string, mappings map[string]string) error
LoadBalancerAddIPPortMapping add load balancer ip port mapping
func (*OVNNbClient) LoadBalancerAddVip ¶ added in v1.12.1
func (c *OVNNbClient) LoadBalancerAddVip(lbName, vip string, backends ...string) error
LoadBalancerAddVips adds or updates a vip
func (*OVNNbClient) LoadBalancerDeleteHealthCheck ¶ added in v1.12.2
func (c *OVNNbClient) LoadBalancerDeleteHealthCheck(lbName, uuid string) error
LoadBalancerDeleteHealthCheck delete load balancer health check
func (*OVNNbClient) LoadBalancerDeleteIPPortMapping ¶ added in v1.12.2
func (c *OVNNbClient) LoadBalancerDeleteIPPortMapping(lbName, vipEndpoint string) error
LoadBalancerDeleteIPPortMapping delete load balancer ip port mapping
func (*OVNNbClient) LoadBalancerDeleteVip ¶ added in v1.12.1
func (c *OVNNbClient) LoadBalancerDeleteVip(lbName, vipEndpoint string, ignoreHealthCheck bool) error
LoadBalancerDeleteVip deletes load balancer vip
func (*OVNNbClient) LoadBalancerExists ¶ added in v1.12.1
func (c *OVNNbClient) LoadBalancerExists(lbName string) (bool, error)
func (*OVNNbClient) LoadBalancerHealthCheckExists ¶ added in v1.12.2
func (c *OVNNbClient) LoadBalancerHealthCheckExists(lbName, vipEndpoint string) (bool, error)
LoadBalancerHealthCheckExists get lb health check and return the result of existence
func (*OVNNbClient) LoadBalancerOp ¶ added in v1.12.1
func (c *OVNNbClient) LoadBalancerOp(lbName string, mutationsFunc ...func(lb *ovnnb.LoadBalancer) []model.Mutation) ([]ovsdb.Operation, error)
func (*OVNNbClient) LoadBalancerUpdateHealthCheckOp ¶ added in v1.12.2
func (c *OVNNbClient) LoadBalancerUpdateHealthCheckOp(lbName string, lbhcUUIDs []string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
LoadBalancerUpdateHealthCheckOp create operations add to or delete health check from it
func (*OVNNbClient) LoadBalancerUpdateIPPortMapping ¶ added in v1.12.2
func (c *OVNNbClient) LoadBalancerUpdateIPPortMapping(lbName, vipEndpoint string, ipPortMappings map[string]string) error
LoadBalancerUpdateIPPortMapping update load balancer ip port mapping
func (*OVNNbClient) LogicalRouterExists ¶ added in v1.12.1
func (c *OVNNbClient) LogicalRouterExists(name string) (bool, error)
func (*OVNNbClient) LogicalRouterOp ¶ added in v1.12.1
func (c *OVNNbClient) LogicalRouterOp(lrName string, mutationsFunc ...func(lr *ovnnb.LogicalRouter) *model.Mutation) ([]ovsdb.Operation, error)
LogicalRouterOp create operations about logical router
func (*OVNNbClient) LogicalRouterPortExists ¶ added in v1.12.1
func (c *OVNNbClient) LogicalRouterPortExists(lrpName string) (bool, error)
func (*OVNNbClient) LogicalRouterPortOp ¶ added in v1.12.1
func (c *OVNNbClient) LogicalRouterPortOp(lrpName string, mutationsFunc ...func(lrp *ovnnb.LogicalRouterPort) *model.Mutation) ([]ovsdb.Operation, error)
LogicalRouterPortOp create operations about logical router port
func (*OVNNbClient) LogicalRouterPortUpdateGatewayChassisOp ¶ added in v1.12.1
func (c *OVNNbClient) LogicalRouterPortUpdateGatewayChassisOp(lrpName string, uuids []string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
LogicalRouterPortUpdateGatewayChassisOp create operations add to or delete gateway chassis from logical router port
func (*OVNNbClient) LogicalRouterStaticRouteExists ¶ added in v1.12.1
func (c *OVNNbClient) LogicalRouterStaticRouteExists(lrName, routeTable, policy, ipPrefix, nexthop string) (bool, error)
func (*OVNNbClient) LogicalRouterUpdateLoadBalancers ¶ added in v1.12.1
func (c *OVNNbClient) LogicalRouterUpdateLoadBalancers(lrName string, op ovsdb.Mutator, lbNames ...string) error
LogicalRouterUpdateLoadBalancers add several lb to or from logical router once
func (*OVNNbClient) LogicalRouterUpdateNatOp ¶ added in v1.12.1
func (c *OVNNbClient) LogicalRouterUpdateNatOp(lrName string, natUUIDs []string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
LogicalRouterUpdateNatOp create operations add to or delete nat rule from logical router
func (*OVNNbClient) LogicalRouterUpdatePolicyOp ¶ added in v1.12.1
func (c *OVNNbClient) LogicalRouterUpdatePolicyOp(lrName string, policyUUIDs []string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
LogicalRouterUpdatePolicyOp create operations add to or delete policy from logical router
func (*OVNNbClient) LogicalRouterUpdatePortOp ¶ added in v1.12.1
func (c *OVNNbClient) LogicalRouterUpdatePortOp(lrName, lrpUUID string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
LogicalRouterUpdatePortOp create operations add to or delete port from logical router
func (*OVNNbClient) LogicalRouterUpdateStaticRouteOp ¶ added in v1.12.1
func (c *OVNNbClient) LogicalRouterUpdateStaticRouteOp(lrName string, routeUUIDs []string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
LogicalRouterUpdateStaticRouteOp create operations add to or delete static route from logical router
func (*OVNNbClient) LogicalSwitchAddPort ¶ added in v1.12.1
func (c *OVNNbClient) LogicalSwitchAddPort(lsName, lspName string) error
LogicalSwitchAddPort add port to logical switch
func (*OVNNbClient) LogicalSwitchDelPort ¶ added in v1.12.1
func (c *OVNNbClient) LogicalSwitchDelPort(lsName, lspName string) error
LogicalSwitchDelPort del port from logical switch
func (*OVNNbClient) LogicalSwitchExists ¶ added in v1.12.1
func (c *OVNNbClient) LogicalSwitchExists(lsName string) (bool, error)
func (*OVNNbClient) LogicalSwitchOp ¶ added in v1.12.1
func (c *OVNNbClient) LogicalSwitchOp(lsName string, mutationsFunc ...func(ls *ovnnb.LogicalSwitch) *model.Mutation) ([]ovsdb.Operation, error)
LogicalSwitchOp create operations about logical switch
func (*OVNNbClient) LogicalSwitchPortExists ¶ added in v1.12.1
func (c *OVNNbClient) LogicalSwitchPortExists(name string) (bool, error)
func (*OVNNbClient) LogicalSwitchUpdateLoadBalancerOp ¶ added in v1.12.1
func (c *OVNNbClient) LogicalSwitchUpdateLoadBalancerOp(lsName string, lbUUIDs []string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
LogicalSwitchUpdateLoadBalancerOp create operations add lb to or delete lb from logical switch
func (*OVNNbClient) LogicalSwitchUpdateLoadBalancers ¶ added in v1.12.1
func (c *OVNNbClient) LogicalSwitchUpdateLoadBalancers(lsName string, op ovsdb.Mutator, lbNames ...string) error
LogicalSwitchUpdateLoadBalancers add several lb to or from logical switch once
func (*OVNNbClient) LogicalSwitchUpdateOtherConfig ¶ added in v1.12.1
func (c *OVNNbClient) LogicalSwitchUpdateOtherConfig(lsName string, op ovsdb.Mutator, otherConfig map[string]string) error
LogicalSwitchUpdateOtherConfig add other config to or from logical switch once
func (*OVNNbClient) LogicalSwitchUpdateOtherConfigOp ¶ added in v1.12.1
func (c *OVNNbClient) LogicalSwitchUpdateOtherConfigOp(lsName string, otherConfig map[string]string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
LogicalSwitchUpdateOtherConfigOp create operations add otherConfig to or delete otherConfig from logical switch
func (*OVNNbClient) LogicalSwitchUpdatePortOp ¶ added in v1.12.1
func (c *OVNNbClient) LogicalSwitchUpdatePortOp(lsName, lspUUID string, op ovsdb.Mutator) ([]ovsdb.Operation, error)
LogicalSwitchUpdatePortOp create operations add port to or delete port from logical switch
func (*OVNNbClient) NatExists ¶ added in v1.12.1
func (c *OVNNbClient) NatExists(lrName, natType, externalIP, logicalIP string) (bool, error)
func (*OVNNbClient) PortGroupAddPorts ¶ added in v1.12.1
func (c *OVNNbClient) PortGroupAddPorts(pgName string, lspNames ...string) error
PortGroupAddPorts add ports to port group
func (*OVNNbClient) PortGroupExists ¶ added in v1.12.1
func (c *OVNNbClient) PortGroupExists(pgName string) (bool, error)
func (*OVNNbClient) PortGroupRemovePorts ¶ added in v1.12.1
func (c *OVNNbClient) PortGroupRemovePorts(pgName string, lspNames ...string) error
PortGroupRemovePorts remove ports from port group
func (*OVNNbClient) PortGroupSetPorts ¶ added in v1.12.1
func (c *OVNNbClient) PortGroupSetPorts(pgName string, ports []string) error
func (*OVNNbClient) PortGroupUpdatePorts ¶ added in v1.12.1
func (c *OVNNbClient) PortGroupUpdatePorts(pgName string, op ovsdb.Mutator, lspNames ...string) error
PortGroupUpdatePorts add several ports to or from port group once
func (*OVNNbClient) RemoveLogicalPatchPort ¶ added in v1.12.1
func (c *OVNNbClient) RemoveLogicalPatchPort(lspName, lrpName string) error
RemoveLogicalPatchPort delete logical router port and associated logical switch port which type is router
func (*OVNNbClient) SGLostACL ¶ added in v1.12.12
func (c *OVNNbClient) SGLostACL(sg *kubeovnv1.SecurityGroup) (bool, error)
SGLostACL check if security group lost an acl
func (*OVNNbClient) SetACLLog ¶ added in v1.12.1
func (c *OVNNbClient) SetACLLog(pgName string, logEnable, isIngress bool) error
func (*OVNNbClient) SetAzName ¶ added in v1.12.1
func (c *OVNNbClient) SetAzName(azName string) error
func (*OVNNbClient) SetICAutoRoute ¶ added in v1.12.1
func (c *OVNNbClient) SetICAutoRoute(enable bool, blackList []string) error
func (*OVNNbClient) SetLBCIDR ¶ added in v1.12.1
func (c *OVNNbClient) SetLBCIDR(serviceCIDR string) error
func (*OVNNbClient) SetLoadBalancerAffinityTimeout ¶ added in v1.12.1
func (c *OVNNbClient) SetLoadBalancerAffinityTimeout(lbName string, timeout int) error
SetLoadBalancerAffinityTimeout sets the LB's affinity timeout in seconds
func (*OVNNbClient) SetLogicalSwitchPortArpProxy ¶ added in v1.12.1
func (c *OVNNbClient) SetLogicalSwitchPortArpProxy(lspName string, enableArpProxy bool) error
func (*OVNNbClient) SetLogicalSwitchPortExternalIDs ¶ added in v1.12.5
func (c *OVNNbClient) SetLogicalSwitchPortExternalIDs(lspName string, externalIDs map[string]string) error
SetLogicalSwitchPortExternalIDs set logical switch port external ids
func (*OVNNbClient) SetLogicalSwitchPortSecurity ¶ added in v1.12.1
func (c *OVNNbClient) SetLogicalSwitchPortSecurity(portSecurity bool, lspName, mac, ips, vips string) error
SetLogicalSwitchPortSecurity set logical switch port port_security
func (*OVNNbClient) SetLogicalSwitchPortSecurityGroup ¶ added in v1.12.1
func (c *OVNNbClient) SetLogicalSwitchPortSecurityGroup(lsp *ovnnb.LogicalSwitchPort, op string, sgs ...string) ([]string, error)
SetLogicalSwitchPortSecurityGroup set logical switch port security group, op is 'add' or 'remove'
func (*OVNNbClient) SetLogicalSwitchPortVirtualParents ¶ added in v1.12.1
func (c *OVNNbClient) SetLogicalSwitchPortVirtualParents(lsName, parents string, ips ...string) error
CreateVirtualLogicalSwitchPorts update several virtual type logical switch port virtual-parents once
func (*OVNNbClient) SetLogicalSwitchPortVlanTag ¶ added in v1.12.1
func (c *OVNNbClient) SetLogicalSwitchPortVlanTag(lspName string, vlanID int) error
func (*OVNNbClient) SetLogicalSwitchPortsSecurityGroup ¶ added in v1.12.1
func (c *OVNNbClient) SetLogicalSwitchPortsSecurityGroup(sgName, op string) error
SetLogicalSwitchPortsSecurityGroup set logical switch port security group, op is 'add' or 'remove'
func (*OVNNbClient) SetLogicalSwitchPrivate ¶ added in v1.12.1
func (c *OVNNbClient) SetLogicalSwitchPrivate(lsName, cidrBlock, nodeSwitchCIDR string, allowSubnets []string) error
SetLogicalSwitchPrivate will drop all ingress traffic except allow subnets, same subnet and node subnet
func (*OVNNbClient) SetLsCtSkipDstLportIPs ¶ added in v1.12.5
func (c *OVNNbClient) SetLsCtSkipDstLportIPs(enabled bool) error
func (*OVNNbClient) SetLsDnatModDlDst ¶ added in v1.12.1
func (c *OVNNbClient) SetLsDnatModDlDst(enabled bool) error
func (*OVNNbClient) SetNbGlobalOptions ¶ added in v1.12.1
func (c *OVNNbClient) SetNbGlobalOptions(key string, value interface{}) error
func (*OVNNbClient) SetUseCtInvMatch ¶ added in v1.12.1
func (c *OVNNbClient) SetUseCtInvMatch() error
func (*OVNNbClient) UpdateACL ¶ added in v1.12.1
func (c *OVNNbClient) UpdateACL(acl *ovnnb.ACL, fields ...interface{}) error
UpdateACL update acl
func (*OVNNbClient) UpdateAddressSet ¶ added in v1.12.1
func (c *OVNNbClient) UpdateAddressSet(as *ovnnb.AddressSet, fields ...interface{}) error
UpdateAddressSet update address set
func (*OVNNbClient) UpdateDHCPOptions ¶ added in v1.12.1
func (c *OVNNbClient) UpdateDHCPOptions(subnet *kubeovnv1.Subnet, mtu int) (*DHCPOptionsUUIDs, error)
func (*OVNNbClient) UpdateDnatAndSnat ¶ added in v1.12.1
func (c *OVNNbClient) UpdateDnatAndSnat(lrName, externalIP, logicalIP, lspName, externalMac, gatewayType string) error
UpdateDnatAndSnat update dnat_and_snat rule
func (*OVNNbClient) UpdateEgressACLOps ¶ added in v1.12.1
func (c *OVNNbClient) UpdateEgressACLOps(pgName, asEgressName, asExceptName, protocol string, npp []netv1.NetworkPolicyPort, logEnable bool, namedPortMap map[string]*util.NamedPortInfo) ([]ovsdb.Operation, error)
UpdateEgressACLOps return operation that creates an egress ACL
func (*OVNNbClient) UpdateIngressACLOps ¶ added in v1.12.1
func (c *OVNNbClient) UpdateIngressACLOps(pgName, asIngressName, asExceptName, protocol string, npp []netv1.NetworkPolicyPort, logEnable bool, namedPortMap map[string]*util.NamedPortInfo) ([]ovsdb.Operation, error)
UpdateIngressACLOps return operation that creates an ingress ACL
func (*OVNNbClient) UpdateLoadBalancer ¶ added in v1.12.1
func (c *OVNNbClient) UpdateLoadBalancer(lb *ovnnb.LoadBalancer, fields ...interface{}) error
UpdateLoadBalancer update load balancer
func (*OVNNbClient) UpdateLoadBalancerHealthCheck ¶ added in v1.12.2
func (c *OVNNbClient) UpdateLoadBalancerHealthCheck(lbhc *ovnnb.LoadBalancerHealthCheck, fields ...interface{}) error
UpdateLoadBalancerHealthCheck update lb
func (*OVNNbClient) UpdateLogicalRouter ¶ added in v1.12.1
func (c *OVNNbClient) UpdateLogicalRouter(lr *ovnnb.LogicalRouter, fields ...interface{}) error
UpdateLogicalRouter update logical router
func (*OVNNbClient) UpdateLogicalRouterOp ¶ added in v1.12.1
func (c *OVNNbClient) UpdateLogicalRouterOp(lr *ovnnb.LogicalRouter, fields ...interface{}) ([]ovsdb.Operation, error)
UpdateLogicalRouterOp generate operations which update logical router
func (*OVNNbClient) UpdateLogicalRouterPort ¶ added in v1.12.1
func (c *OVNNbClient) UpdateLogicalRouterPort(lrp *ovnnb.LogicalRouterPort, fields ...interface{}) error
UpdateLogicalRouterPort update logical router port
func (*OVNNbClient) UpdateLogicalRouterPortOptions ¶ added in v1.12.1
func (c *OVNNbClient) UpdateLogicalRouterPortOptions(lrpName string, options map[string]string) error
func (*OVNNbClient) UpdateLogicalRouterPortRA ¶ added in v1.12.1
func (c *OVNNbClient) UpdateLogicalRouterPortRA(lrpName, ipv6RAConfigsStr string, enableIPv6RA bool) error
func (*OVNNbClient) UpdateLogicalRouterStaticRoute ¶ added in v1.12.1
func (c *OVNNbClient) UpdateLogicalRouterStaticRoute(route *ovnnb.LogicalRouterStaticRoute, fields ...interface{}) error
UpdateLogicalRouterStaticRoute update logical router static route
func (*OVNNbClient) UpdateLogicalSwitchACL ¶ added in v1.12.1
func (c *OVNNbClient) UpdateLogicalSwitchACL(lsName string, subnetAcls []kubeovnv1.ACL) error
func (*OVNNbClient) UpdateLogicalSwitchPort ¶ added in v1.12.1
func (c *OVNNbClient) UpdateLogicalSwitchPort(lsp *ovnnb.LogicalSwitchPort, fields ...interface{}) error
UpdateLogicalSwitchPort update logical switch port
func (*OVNNbClient) UpdateLogicalSwitchPortOp ¶ added in v1.12.1
func (c *OVNNbClient) UpdateLogicalSwitchPortOp(lsp *ovnnb.LogicalSwitchPort, fields ...interface{}) ([]ovsdb.Operation, error)
UpdateLogicalSwitchPortOp create operations which update logical switch port
func (*OVNNbClient) UpdateNat ¶ added in v1.12.1
func (c *OVNNbClient) UpdateNat(nat *ovnnb.NAT, fields ...interface{}) error
UpdateNat update nat
func (*OVNNbClient) UpdateNbGlobal ¶ added in v1.12.1
func (c *OVNNbClient) UpdateNbGlobal(nbGlobal *ovnnb.NBGlobal, fields ...interface{}) error
func (*OVNNbClient) UpdatePortGroup ¶ added in v1.12.1
func (c *OVNNbClient) UpdatePortGroup(pg *ovnnb.PortGroup, fields ...interface{}) error
UpdatePortGroup update port group
func (*OVNNbClient) UpdateSgACL ¶ added in v1.12.1
func (c *OVNNbClient) UpdateSgACL(sg *kubeovnv1.SecurityGroup, direction string) error
func (*OVNNbClient) UpdateSnat ¶ added in v1.12.1
func (c *OVNNbClient) UpdateSnat(lrName, externalIP, logicalIP string) error
UpdateSnat update snat rule
type OVNSbClient ¶ added in v1.12.1
type OVNSbClient struct {
// contains filtered or unexported fields
}
func NewOvnSbClient ¶ added in v1.12.1
func NewOvnSbClient(ovnSbAddr string, ovnSbTimeout int) (*OVNSbClient, error)
func (*OVNSbClient) DeleteChassis ¶ added in v1.12.1
func (c *OVNSbClient) DeleteChassis(chassisName string) error
DeleteChassis delete one chassis by name
func (*OVNSbClient) DeleteChassisByHost ¶ added in v1.12.1
func (c *OVNSbClient) DeleteChassisByHost(nodeName string) error
DeleteChassisByHost delete all chassis by node name
func (*OVNSbClient) GetAllChassisByHost ¶ added in v1.12.1
func (c *OVNSbClient) GetAllChassisByHost(nodeName string) (*[]ovnsb.Chassis, error)
func (*OVNSbClient) GetChassis ¶ added in v1.12.1
GetChassis return south bound db chassis from cache
func (*OVNSbClient) GetChassisByHost ¶ added in v1.12.1
func (c *OVNSbClient) GetChassisByHost(nodeName string) (*ovnsb.Chassis, error)
func (*OVNSbClient) GetEntityInfo ¶ added in v1.12.1
func (c *OVNSbClient) GetEntityInfo(entity interface{}) error
GetEntityInfo get entity info by column which is the index, reference to ovn-nb.ovsschema(ovsdb-client get-schema unix:/var/run/ovn/ovnnb_db.sock OVN_Northbound) for more information, UUID is index
func (*OVNSbClient) GetKubeOvnChassisses ¶ added in v1.12.1
func (c *OVNSbClient) GetKubeOvnChassisses() (*[]ovnsb.Chassis, error)
GetKubeOvnChassisses return all chassis which vendor is kube-ovn
func (*OVNSbClient) ListChassis ¶ added in v1.12.1
func (c *OVNSbClient) ListChassis() (*[]ovnsb.Chassis, error)
ListChassis return south bound db chassis from cache
func (*OVNSbClient) UpdateChassis ¶ added in v1.12.1
func (c *OVNSbClient) UpdateChassis(chassis *ovnsb.Chassis, fields ...interface{}) error
func (*OVNSbClient) UpdateChassisTag ¶ added in v1.12.1
func (c *OVNSbClient) UpdateChassisTag(chassisName, nodeName string) error
type OrACLMatch ¶ added in v1.12.1
type OrACLMatch struct {
// contains filtered or unexported fields
}
func (OrACLMatch) Match ¶ added in v1.12.1
func (m OrACLMatch) Match() (string, error)
Match generate acl match like '(ip4.src==10.250.0.0/16 && ip4.dst==10.244.0.0/16) || (ip4.src==10.244.0.0/16 && ip4.dst==10.250.0.0/16)'
func (OrACLMatch) String ¶ added in v1.12.1
func (m OrACLMatch) String() string
type PortGroup ¶ added in v1.12.0
type PortGroup interface { CreatePortGroup(pgName string, externalIDs map[string]string) error PortGroupAddPorts(pgName string, lspNames ...string) error PortGroupRemovePorts(pgName string, lspNames ...string) error PortGroupSetPorts(pgName string, ports []string) error DeletePortGroup(pgName string) error ListPortGroups(externalIDs map[string]string) ([]ovnnb.PortGroup, error) GetPortGroup(pgName string, ignoreNotFound bool) (*ovnnb.PortGroup, error) PortGroupExists(pgName string) (bool, error) }
Source Files ¶
- adapter.go
- interface.go
- ovn-ic-nbctl.go
- ovn-ic-sbctl.go
- ovn-nb-acl.go
- ovn-nb-address_set.go
- ovn-nb-bfd.go
- ovn-nb-dhcp_options.go
- ovn-nb-gateway_chassis.go
- ovn-nb-load_balancer.go
- ovn-nb-load_balancer_health_check.go
- ovn-nb-logical_router.go
- ovn-nb-logical_router_policy.go
- ovn-nb-logical_router_port.go
- ovn-nb-logical_router_route.go
- ovn-nb-logical_switch.go
- ovn-nb-logical_switch_port.go
- ovn-nb-nat.go
- ovn-nb-port_group.go
- ovn-nb.go
- ovn-nb_global.go
- ovn-sb-chassis.go
- ovn.go
- ovs-ofctl.go
- ovs-vsctl.go
- ovs-vsctl_linux.go
- util.go