Skip to content

Commit b057767

Browse files
committed
debug node: Run under an unconfined SELinux context
Run the node debug pod under an unconfined SELinux context (unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023) to avoid issues with the `spc_t` context. Fixes: #641 See also: - https://bugzilla.redhat.com/show_bug.cgi?id=1839065 - https://bugzilla.redhat.com/show_bug.cgi?id=1896369
1 parent ea20e4c commit b057767

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

pkg/cli/debug/debug.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1045,6 +1045,12 @@ func (o *DebugOptions) approximatePodTemplateForObject(object runtime.Object) (*
10451045
SecurityContext: &corev1.SecurityContext{
10461046
Privileged: &isTrue,
10471047
RunAsUser: &zero,
1048+
SELinuxOptions: &corev1.SELinuxOptions{
1049+
User: "unconfined_u",
1050+
Role: "unconfined_r",
1051+
Type: "unconfined_t",
1052+
Level: "s0-s0:c0.c1023",
1053+
},
10481054
},
10491055
VolumeMounts: []corev1.VolumeMount{
10501056
{

0 commit comments

Comments
 (0)