Merge pull request #9965 from stevekuznetsov/skuznets/allow-https

Allowing for HTTPS Probes
This commit is contained in:
Robert Bailey
2015-06-26 10:43:37 -07:00
25 changed files with 162 additions and 97 deletions

View File

@@ -763,6 +763,10 @@ func validateHTTPGetAction(http *api.HTTPGetAction) errs.ValidationErrorList {
} else if http.Port.Kind == util.IntstrString && !util.IsValidPortName(http.Port.StrVal) {
allErrors = append(allErrors, errs.NewFieldInvalid("port", http.Port.StrVal, portNameErrorMsg))
}
supportedSchemes := util.NewStringSet(string(api.URISchemeHTTP), string(api.URISchemeHTTPS))
if !supportedSchemes.Has(string(http.Scheme)) {
allErrors = append(allErrors, errs.NewFieldInvalid("scheme", http.Scheme, fmt.Sprintf("must be one of %v", supportedSchemes.List())))
}
return allErrors
}