Skip to content

Commit

Permalink
add NET_RAW to allow pods to ping
Browse files Browse the repository at this point in the history
Signed-off-by: Sebastian Sch <[email protected]>
  • Loading branch information
SchSeba committed Jan 28, 2024
1 parent 48808ae commit eaa81ce
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion test/util/pod/pod.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,11 @@ func GetDefinition() *corev1.Pod {
Spec: corev1.PodSpec{
TerminationGracePeriodSeconds: pointer.Int64Ptr(0),
Containers: []corev1.Container{{Name: "test",
Image: images.Test(),
Image: images.Test(),
SecurityContext: &corev1.SecurityContext{
Capabilities: &corev1.Capabilities{
Add: []corev1.Capability{"NET_RAW"},
}},
Command: []string{"/bin/bash", "-c", "sleep INF"}}}}}

return podObject
Expand Down

0 comments on commit eaa81ce

Please sign in to comment.