- Sort Score
- Result 10 results
- Languages All
Results 1 - 8 of 8 for AddPodToMesh (0.08 sec)
-
cni/pkg/nodeagent/server_test.go
server := &fakeServer{} server.On("AddPodToMesh", fakeCtx, pod, podIPs, "", ).Return(nil) server.Start(fakeCtx) fakeIPSetDeps := ipset.FakeNLDeps() set := ipset.IPSet{V4Name: "foo-v4", Prefix: "foo", Deps: fakeIPSetDeps} m := getFakeDPWithIPSet(server, fakeClientSet, set) expectPodAddedToIPSet(fakeIPSetDeps, podIP, pod.ObjectMeta) err := m.AddPodToMesh(fakeCtx, pod, podIPs, "")
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Wed Oct 09 16:05:45 UTC 2024 - 18.7K bytes - Viewed (0) -
cni/pkg/nodeagent/net_test.go
podMeta := metav1.ObjectMeta{ Name: "foo", Namespace: "bar", UID: "123", } podIP := netip.MustParseAddr("99.9.9.9") podIPs := []netip.Addr{podIP} err := netServer.AddPodToMesh(ctx, &corev1.Pod{ObjectMeta: podMeta}, podIPs, "fakenetns") assert.NoError(t, err) assert.Equal(t, 1, ztunnelServer.addedPods.Load()) } func TestServerRemovePod(t *testing.T) {
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Thu Jul 25 16:13:38 UTC 2024 - 10.7K bytes - Viewed (0) -
cni/pkg/nodeagent/net.go
// // We always need the IPs, but this is fine because this AddPodToMesh can be called from the CNI plugin as well, // which always has the firsthand info of the IPs, even before K8S does - so we pass them separately here because // we actually may have them before K8S in the Pod object. func (s *NetServer) AddPodToMesh(ctx context.Context, pod *corev1.Pod, podIPs []netip.Addr, netNs string) error {
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Mon Oct 21 16:48:55 UTC 2024 - 9.1K bytes - Viewed (0) -
cni/pkg/nodeagent/informers_test.go
client := kube.NewFakeClient(ns, pod) // We are expecting at most 1 calls to the mock, wait for them wg, waitForMockCalls := NewWaitForNCalls(t, 1) fs := &fakeServer{testWG: wg} fs.On("AddPodToMesh", ctx, mock.IsType(pod), util.GetPodIPsIfPresent(pod), "", ).Return(nil) server := getFakeDP(fs, client.Kube()) handlers := setupHandlers(ctx, client, server, "istio-system")
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Wed Oct 09 16:05:45 UTC 2024 - 22.1K bytes - Viewed (0) -
cni/pkg/nodeagent/cni-watcher_test.go
client := kube.NewFakeClient(ns, pod) // We are expecting at most 1 calls to the mock, wait for them wg, waitForMockCalls := NewWaitForNCalls(t, 1) fs := &fakeServer{testWG: wg} fs.On("AddPodToMesh", ctx, mock.IsType(pod), util.GetPodIPsIfPresent(pod), valid.Netns, ).Return(nil) dpServer := getFakeDP(fs, client.Kube())
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Wed Oct 09 16:05:45 UTC 2024 - 7.6K bytes - Viewed (0) -
cni/pkg/nodeagent/server.go
return err } return s.netServer.ConstructInitialSnapshot(ambientPods) } func (s *meshDataplane) AddPodToMesh(ctx context.Context, pod *corev1.Pod, podIPs []netip.Addr, netNs string) error { var retErr error err := s.netServer.AddPodToMesh(ctx, pod, podIPs, netNs) if err != nil { log.Errorf("failed to add pod to ztunnel: %v", err) if !errors.Is(err, ErrPartialAdd) { return err
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Wed Sep 25 20:54:34 UTC 2024 - 13.4K bytes - Viewed (0) -
cni/pkg/nodeagent/cni-watcher.go
} // Note that we use the IP info from the CNI plugin here - the Pod struct as reported by K8S doesn't have this info // yet (because the K8S control plane doesn't), so it will be empty there. err = s.dataplane.AddPodToMesh(ctx, ambientPod, podIps, addCmd.Netns) if err != nil { return err } return nil } func (s *CniPluginServer) getPodWithRetry(log *istiolog.Scope, name, namespace string) (*corev1.Pod, error) {
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Tue Jul 02 18:48:50 UTC 2024 - 6.7K bytes - Viewed (0) -
cni/pkg/nodeagent/informers.go
log.Debugf("pod update event skipped: no IP assigned yet") return nil } log.Debugf("pod is now enrolled, adding to mesh") err := s.dataplane.AddPodToMesh(s.ctx, pod, podIPs, "") if err != nil { log.Warnf("AddPodToMesh returned: %v", err) } } case controllers.EventDelete: // We are the only thing that should be annotating the pods for mesh inclusion.
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Wed Oct 09 16:05:45 UTC 2024 - 11.7K bytes - Viewed (0)