Documentation
¶
Index ¶
- func NewLocalPodSpecFromAdd(request *pb.AddRequest) (*storage.LocalPodSpec, error)
- func NewLocalPodSpecFromDel(request *pb.DelRequest) *storage.LocalPodSpec
- type Server
- func (s *Server) Add(ctx context.Context, request *pb.AddRequest) (*pb.AddReply, error)
- func (s *Server) AddVppInterface(podSpec *storage.LocalPodSpec, doHostSideConf bool) (swIfIndex uint32, err error)
- func (s *Server) Del(ctx context.Context, request *pb.DelRequest) (*pb.DelReply, error)
- func (s *Server) DelVppInterface(podSpec *storage.LocalPodSpec) error
- func (p *Server) IPNetNeedsSNAT(prefix *net.IPNet) bool
- func (p *Server) OnVppRestart()
- func (s *Server) PodSpecNeedsSnat(ps *storage.LocalPodSpec) (needsSnat bool)
- func (s *Server) Serve()
- func (s *Server) SetupVppRoutes(swIfIndex uint32, podSpec *storage.LocalPodSpec) error
- func (s *Server) Stop()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewLocalPodSpecFromAdd ¶
func NewLocalPodSpecFromAdd(request *pb.AddRequest) (*storage.LocalPodSpec, error)
func NewLocalPodSpecFromDel ¶
func NewLocalPodSpecFromDel(request *pb.DelRequest) *storage.LocalPodSpec
Types ¶
type Server ¶
type Server struct { *common.CalicoVppServerData /* without main thread */ NumVPPWorkers uint32 // contains filtered or unexported fields }
func NewServer ¶
func NewServer(v *vpplink.VppLink, rs *routing.Server, ps *policy.Server, l *logrus.Entry) (*Server, error)
Serve runs the grpc server for the Calico CNI backend API
func (*Server) AddVppInterface ¶
func (s *Server) AddVppInterface(podSpec *storage.LocalPodSpec, doHostSideConf bool) (swIfIndex uint32, err error)
AddVppInterface performs the networking for the given config and IPAM result
func (*Server) DelVppInterface ¶
func (s *Server) DelVppInterface(podSpec *storage.LocalPodSpec) error
CleanUpVPPNamespace deletes the devices in the network namespace.
func (*Server) OnVppRestart ¶
func (p *Server) OnVppRestart()
func (*Server) PodSpecNeedsSnat ¶
func (s *Server) PodSpecNeedsSnat(ps *storage.LocalPodSpec) (needsSnat bool)
func (*Server) SetupVppRoutes ¶
func (s *Server) SetupVppRoutes(swIfIndex uint32, podSpec *storage.LocalPodSpec) error
SetupRoutes sets up the routes for the host side of the veth pair.
Click to show internal directories.
Click to hide internal directories.