|
|
@ -368,6 +368,9 @@ type Config struct { |
|
|
|
// HttpAuth is the auth info to use for http access.
|
|
|
|
// HttpAuth is the auth info to use for http access.
|
|
|
|
HttpAuth *HttpBasicAuth |
|
|
|
HttpAuth *HttpBasicAuth |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// HostOverride is the override to host. Default is Address.
|
|
|
|
|
|
|
|
HostOverride string |
|
|
|
|
|
|
|
|
|
|
|
// WaitTime limits how long a Watch will block. If not provided,
|
|
|
|
// WaitTime limits how long a Watch will block. If not provided,
|
|
|
|
// the agent default values will be used.
|
|
|
|
// the agent default values will be used.
|
|
|
|
WaitTime time.Duration |
|
|
|
WaitTime time.Duration |
|
|
@ -1029,6 +1032,9 @@ func (r *request) toHTTP() (*http.Request, error) { |
|
|
|
req.URL.Host = r.url.Host |
|
|
|
req.URL.Host = r.url.Host |
|
|
|
req.URL.Scheme = r.url.Scheme |
|
|
|
req.URL.Scheme = r.url.Scheme |
|
|
|
req.Host = r.url.Host |
|
|
|
req.Host = r.url.Host |
|
|
|
|
|
|
|
if r.config.HostOverride != "" { |
|
|
|
|
|
|
|
req.Host = r.config.HostOverride |
|
|
|
|
|
|
|
} |
|
|
|
req.Header = r.header |
|
|
|
req.Header = r.header |
|
|
|
|
|
|
|
|
|
|
|
// Content-Type must always be set when a body is present
|
|
|
|
// Content-Type must always be set when a body is present
|
|
|
|