mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-14 13:45:06 +00:00
Merge pull request #9965 from stevekuznetsov/skuznets/allow-https
Allowing for HTTPS Probes
This commit is contained in:
@@ -592,6 +592,7 @@ func convert_api_HTTPGetAction_To_v1_HTTPGetAction(in *api.HTTPGetAction, out *H
|
||||
return err
|
||||
}
|
||||
out.Host = in.Host
|
||||
out.Scheme = URIScheme(in.Scheme)
|
||||
return nil
|
||||
}
|
||||
|
||||
@@ -2903,6 +2904,7 @@ func convert_v1_HTTPGetAction_To_api_HTTPGetAction(in *HTTPGetAction, out *api.H
|
||||
return err
|
||||
}
|
||||
out.Host = in.Host
|
||||
out.Scheme = api.URIScheme(in.Scheme)
|
||||
return nil
|
||||
}
|
||||
|
||||
|
@@ -518,6 +518,7 @@ func deepCopy_v1_HTTPGetAction(in HTTPGetAction, out *HTTPGetAction, c *conversi
|
||||
return err
|
||||
}
|
||||
out.Host = in.Host
|
||||
out.Scheme = in.Scheme
|
||||
return nil
|
||||
}
|
||||
|
||||
|
@@ -137,6 +137,9 @@ func addDefaultingFuncs() {
|
||||
if obj.Path == "" {
|
||||
obj.Path = "/"
|
||||
}
|
||||
if obj.Scheme == "" {
|
||||
obj.Scheme = URISchemeHTTP
|
||||
}
|
||||
},
|
||||
func(obj *NamespaceStatus) {
|
||||
if obj.Phase == "" {
|
||||
|
@@ -592,8 +592,20 @@ type HTTPGetAction struct {
|
||||
Port util.IntOrString `json:"port" description:"number or name of the port to access on the container; number must be in the range 1 to 65535; name must be a IANA_SVC_NAME"`
|
||||
// Optional: Host name to connect to, defaults to the pod IP.
|
||||
Host string `json:"host,omitempty" description:"hostname to connect to; defaults to pod IP"`
|
||||
// Optional: Scheme to use for connecting to the host, defaults to HTTP.
|
||||
Scheme URIScheme `json:"scheme,omitempty" description:"scheme to connect with, must be HTTP or HTTPS, defaults to HTTP"`
|
||||
}
|
||||
|
||||
// URIScheme identifies the scheme used for connection to a host for Get actions
|
||||
type URIScheme string
|
||||
|
||||
const (
|
||||
// URISchemeHTTP means that the scheme used will be http://
|
||||
URISchemeHTTP URIScheme = "HTTP"
|
||||
// URISchemeHTTPS means that the scheme used will be https://
|
||||
URISchemeHTTPS URIScheme = "HTTPS"
|
||||
)
|
||||
|
||||
// TCPSocketAction describes an action based on opening a socket
|
||||
type TCPSocketAction struct {
|
||||
// Required: Port to connect to.
|
||||
|
Reference in New Issue
Block a user