Merge pull request #65238 from deads2k/scheduler-01-boundary

Automatic merge from submit-queue (batch tested with PRs 65187, 65206, 65223, 64752, 65238). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

fix scheduler port boundary to match detection

zero is allowed to disable the port.  Fix boundary check to allow it.

```release-note
NONE
```

No release note because if we fix it in time, nothing was wrong.
pull/8/head
Kubernetes Submit Queue 2018-06-21 19:48:18 -07:00 committed by GitHub
commit 5e8b64f990
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -152,7 +152,7 @@ func (o *CombinedInsecureServingOptions) Validate() []error {
errors := []error{} errors := []error{}
if o.BindPort <= 0 || o.BindPort > 32767 { if o.BindPort < 0 || o.BindPort > 32767 {
errors = append(errors, fmt.Errorf("--port %v must be between 0 and 32767, inclusive. 0 for turning off insecure (HTTP) port", o.BindPort)) errors = append(errors, fmt.Errorf("--port %v must be between 0 and 32767, inclusive. 0 for turning off insecure (HTTP) port", o.BindPort))
} }