mirror of
https://github.com/k3s-io/kubernetes.git
synced 2026-01-06 16:06:51 +00:00
provider_test.go: use existing method instead of own copy of it.
Also: - rename variables according to its meaning - improve godoc comment
This commit is contained in:
@@ -324,7 +324,7 @@ func (s *simpleProvider) ValidateContainerSecurityContext(pod *api.Pod, containe
|
||||
return allErrs
|
||||
}
|
||||
|
||||
// hasHostPort checks the port definitions on the container for HostPort > 0.
|
||||
// hasInvalidHostPort checks whether the port definitions on the container fall outside of the ranges allowed by the PSP.
|
||||
func (s *simpleProvider) hasInvalidHostPort(container *api.Container, fldPath *field.Path) field.ErrorList {
|
||||
allErrs := field.ErrorList{}
|
||||
for _, cp := range container.Ports {
|
||||
|
||||
Reference in New Issue
Block a user