mirror of
https://github.com/k3s-io/kubernetes.git
synced 2026-01-04 23:17:50 +00:00
Inline some SecurityContext fields into PodSecurityContext
This commit is contained in:
@@ -2650,7 +2650,12 @@ func autoconvert_api_SecurityContext_To_v1_SecurityContext(in *api.SecurityConte
|
||||
} else {
|
||||
out.RunAsUser = nil
|
||||
}
|
||||
out.RunAsNonRoot = in.RunAsNonRoot
|
||||
if in.RunAsNonRoot != nil {
|
||||
out.RunAsNonRoot = new(bool)
|
||||
*out.RunAsNonRoot = *in.RunAsNonRoot
|
||||
} else {
|
||||
out.RunAsNonRoot = nil
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
@@ -5666,7 +5671,12 @@ func autoconvert_v1_SecurityContext_To_api_SecurityContext(in *SecurityContext,
|
||||
} else {
|
||||
out.RunAsUser = nil
|
||||
}
|
||||
out.RunAsNonRoot = in.RunAsNonRoot
|
||||
if in.RunAsNonRoot != nil {
|
||||
out.RunAsNonRoot = new(bool)
|
||||
*out.RunAsNonRoot = *in.RunAsNonRoot
|
||||
} else {
|
||||
out.RunAsNonRoot = nil
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user