Replies: 5 comments 8 replies
-
Look at containerd/pkg/cri/server/sandbox_run.go Line 284 in 96de54d https://github.com/containerd/containerd/blob/main/pkg/cri/server/sandbox_run.go#L335 Let me know if that helps |
Beta Was this translation helpful? Give feedback.
-
The network is only set up once. The first link is for creating the network namespace and the second link is for executing the setup of the network namespace for the container via a CNI plugin. |
Beta Was this translation helpful? Give feedback.
-
Check more closely. You’ll notice that one is executed with the user namespace enabled and the other is executed with user namespaces disabled. The code is a little messy. I made the same mistake a couple weeks ago |
Beta Was this translation helpful? Give feedback.
-
Line 262 and line 381 |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
Could anyone give an example of code snippets of how to use CNI plugin to set up the network and attach to a container with port forwarding capability programmatically?
My code skeleton now looks like this:
Beta Was this translation helpful? Give feedback.
All reactions