Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultHTTPClient = &http.Client{ Transport: &http.Transport{ DisableKeepAlives: true, Proxy: func(req *http.Request) (*url.URL, error) { req.Header.Set("User-Agent", version.UserAgent()) return httpproxy.FromEnvironment().ProxyFunc()(req.URL) }, }, }
DefaultHTTPClient is the default HTTP client used by the Unikraft CLI. It sets a custom User-Agent header and uses the environment's proxy settings, which allows for easy debugging.
View Source
var InsecureHTTPClient = &http.Client{ Transport: &http.Transport{ TLSClientConfig: &tls.Config{InsecureSkipVerify: true}, DisableKeepAlives: true, Proxy: func(req *http.Request) (*url.URL, error) { req.Header.Set("User-Agent", version.UserAgent()) return httpproxy.FromEnvironment().ProxyFunc()(req.URL) }, }, }
InsecureHTTPClient is an HTTP client that skips TLS verification. It is intended for use in development or testing environments where self-signed certificates may be used.
Functions ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.