Skip to content

Commit

Permalink
Fix: executor container security context does not work (kubeflow#2306)
Browse files Browse the repository at this point in the history
Signed-off-by: Yi Chen <[email protected]>
(cherry picked from commit 171e429)
  • Loading branch information
ChenYi015 committed Dec 10, 2024
1 parent e37afbd commit 833ba5c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/webhook/sparkpod_defaulter.go
Original file line number Diff line number Diff line change
Expand Up @@ -537,7 +537,7 @@ func addContainerSecurityContext(pod *corev1.Pod, app *v1beta2.SparkApplication)
if i < 0 {
return fmt.Errorf("executor container not found in pod")
}
if app.Spec.Driver.SecurityContext == nil {
if app.Spec.Executor.SecurityContext == nil {
return nil
}
pod.Spec.Containers[i].SecurityContext = app.Spec.Executor.SecurityContext
Expand Down

0 comments on commit 833ba5c

Please sign in to comment.