1- # kindnetd networking manifest
1+ # source: https://github.com/kubernetes-sigs/kind/blob/v0.27.0/pkg/build/nodeimage/const_cni.go#L28
22---
33kind : ClusterRole
44apiVersion : rbac.authorization.k8s.io/v1
55metadata :
66 name : kindnet
77rules :
8+ - apiGroups :
9+ - policy
10+ resources :
11+ - podsecuritypolicies
12+ verbs :
13+ - use
14+ resourceNames :
15+ - kindnet
816 - apiGroups :
917 - " "
1018 resources :
1119 - nodes
20+ - pods
21+ - namespaces
1222 verbs :
1323 - list
1424 - watch
15- - patch
1625 - apiGroups :
17- - " "
26+ - " networking.k8s.io "
1827 resources :
19- - configmaps
28+ - networkpolicies
2029 verbs :
21- - get
30+ - list
31+ - watch
2232---
2333kind : ClusterRoleBinding
2434apiVersion : rbac.authorization.k8s.io/v1
@@ -29,9 +39,9 @@ roleRef:
2939 kind : ClusterRole
3040 name : kindnet
3141subjects :
32- - kind : ServiceAccount
33- name : kindnet
34- namespace : kube-system
42+ - kind : ServiceAccount
43+ name : kindnet
44+ namespace : kube-system
3545---
3646apiVersion : v1
3747kind : ServiceAccount
@@ -60,55 +70,52 @@ spec:
6070 k8s-app : kindnet
6171 spec :
6272 hostNetwork : true
73+ nodeSelector :
74+ kubernetes.io/os : linux
6375 tolerations :
64- - operator : Exists
65- effect : NoSchedule
76+ - operator : Exists
6677 serviceAccountName : kindnet
6778 containers :
68- - name : kindnet-cni
69- image : kindest/kindnetd:v20230511-dc714da8
70- env :
71- - name : HOST_IP
72- valueFrom :
73- fieldRef :
74- fieldPath : status.hostIP
75- - name : POD_IP
76- valueFrom :
77- fieldRef :
78- fieldPath : status.podIP
79- # We're using the dualstack CIDRs here. The order doesn't matter for kindnet as the loops are run concurrently.
80- # REF: https://github.com/kubernetes-sigs/kind/blob/3dbeb894e3092a336ab4278d3823e73a1d66aff7/images/kindnetd/cmd/kindnetd/main.go#L149-L175
81- - name : POD_SUBNET
82- value : ' ${DOCKER_POD_CIDRS},${DOCKER_POD_IPV6_CIDRS}'
83- volumeMounts :
84- - name : cni-cfg
85- mountPath : /etc/cni/net.d
86- - name : xtables-lock
87- mountPath : /run/xtables.lock
88- readOnly : false
89- - name : lib-modules
90- mountPath : /lib/modules
91- readOnly : true
92- resources :
93- requests :
94- cpu : " 100m"
95- memory : " 50Mi"
96- limits :
97- cpu : " 100m"
98- memory : " 50Mi"
99- securityContext :
100- privileged : false
101- capabilities :
102- add : ["NET_RAW", "NET_ADMIN"]
79+ - name : kindnet-cni
80+ # Needs to be kept in sync with DOCKER_PRELOAD_IMAGES in test/e2e/config/docker.yaml for caching purposes.
81+ image : kindest/kindnetd:v20250214-acbabc1a
82+ env :
83+ - name : HOST_IP
84+ valueFrom :
85+ fieldRef :
86+ fieldPath : status.hostIP
87+ - name : POD_IP
88+ valueFrom :
89+ fieldRef :
90+ fieldPath : status.podIP
91+ # We're using the dualstack CIDRs here. The order doesn't matter for kindnet as the loops are run concurrently.
92+ # REF: https://github.com/kubernetes-sigs/kind/blob/3dbeb894e3092a336ab4278d3823e73a1d66aff7/images/kindnetd/cmd/kindnetd/main.go#L149-L175
93+ - name : POD_SUBNET
94+ value : ' ${DOCKER_POD_CIDRS},${DOCKER_POD_IPV6_CIDRS}'
95+ volumeMounts :
96+ - name : cni-cfg
97+ mountPath : /etc/cni/net.d
98+ - name : xtables-lock
99+ mountPath : /run/xtables.lock
100+ readOnly : false
101+ - name : lib-modules
102+ mountPath : /lib/modules
103+ readOnly : true
104+ resources :
105+ requests :
106+ cpu : " 100m"
107+ memory : " 50Mi"
108+ limits :
109+ cpu : " 100m"
110+ memory : " 50Mi"
111+ securityContext :
112+ privileged : false
113+ capabilities :
114+ add : ["NET_RAW", "NET_ADMIN"]
103115 volumes :
104- - name : cni-bin
105- hostPath :
106- path : /opt/cni/bin
107- type : DirectoryOrCreate
108116 - name : cni-cfg
109117 hostPath :
110118 path : /etc/cni/net.d
111- type : DirectoryOrCreate
112119 - name : xtables-lock
113120 hostPath :
114121 path : /run/xtables.lock
0 commit comments