Versions in this module Expand all Collapse all v0 v0.25.1 Jul 16, 2021 Changes in this version + var DefaultHTTPClientConfig = HTTPClientConfig + func JoinDir(dir, path string) string + func NewAuthorizationCredentialsFileRoundTripper(authType, authCredentialsFile string, rt http.RoundTripper) http.RoundTripper + func NewAuthorizationCredentialsRoundTripper(authType string, authCredentials Secret, rt http.RoundTripper) http.RoundTripper + func NewBasicAuthRoundTripper(username string, password Secret, passwordFile string, rt http.RoundTripper) http.RoundTripper + func NewClientFromConfig(cfg HTTPClientConfig, name string, optFuncs ...HTTPClientOption) (*http.Client, error) + func NewOAuth2RoundTripper(config *OAuth2, next http.RoundTripper) http.RoundTripper + func NewRoundTripperFromConfig(cfg HTTPClientConfig, name string, optFuncs ...HTTPClientOption) (http.RoundTripper, error) + func NewTLSConfig(cfg *TLSConfig) (*tls.Config, error) + func NewTLSRoundTripper(cfg *tls.Config, caFile string, ...) (http.RoundTripper, error) + type Authorization struct + Credentials Secret + CredentialsFile string + Type string + func (a *Authorization) SetDirectory(dir string) + type BasicAuth struct + Password Secret + PasswordFile string + Username string + func (a *BasicAuth) SetDirectory(dir string) + func (a *BasicAuth) UnmarshalYAML(unmarshal func(interface{}) error) error + type DialContextFunc func(context.Context, string, string) (net.Conn, error) + type DirectorySetter interface + SetDirectory func(dir string) + type HTTPClientConfig struct + Authorization *Authorization + BasicAuth *BasicAuth + BearerToken Secret + BearerTokenFile string + FollowRedirects bool + OAuth2 *OAuth2 + ProxyURL URL + TLSConfig TLSConfig + func (c *HTTPClientConfig) SetDirectory(dir string) + func (c *HTTPClientConfig) UnmarshalJSON(data []byte) error + func (c *HTTPClientConfig) UnmarshalYAML(unmarshal func(interface{}) error) error + func (c *HTTPClientConfig) Validate() error + func (c HTTPClientConfig) String() string + type HTTPClientOption func(options *httpClientOptions) + func WithDialContextFunc(fn DialContextFunc) HTTPClientOption + func WithHTTP2Disabled() HTTPClientOption + func WithKeepAlivesDisabled() HTTPClientOption + type OAuth2 struct + ClientID string + ClientSecret Secret + ClientSecretFile string + EndpointParams map[string]string + Scopes []string + TokenURL string + func (a *OAuth2) SetDirectory(dir string) + type Secret string + func (s *Secret) UnmarshalYAML(unmarshal func(interface{}) error) error + func (s Secret) MarshalJSON() ([]byte, error) + func (s Secret) MarshalYAML() (interface{}, error) + type TLSConfig struct + CAFile string + CertFile string + InsecureSkipVerify bool + KeyFile string + ServerName string + func (c *TLSConfig) SetDirectory(dir string) + func (c *TLSConfig) UnmarshalYAML(unmarshal func(interface{}) error) error + type URL struct + func (u *URL) UnmarshalJSON(data []byte) error + func (u *URL) UnmarshalYAML(unmarshal func(interface{}) error) error + func (u URL) MarshalJSON() ([]byte, error) + func (u URL) MarshalYAML() (interface{}, error)