Documentation
¶
Index ¶
- func AddConfig(config *config.Config, outputPath string, kind string, namespace string, ...)
- func AddDescription(config *config.Config, outputPath string, kind string, namespace string, ...)
- func AddKubernetesNodesInformation(cfg *config.Config)
- func AddLogs(cfg *config.Config, path string, namespace string, name string)
- func AddPodHttpEndpointOutput(options AddPodHttpEndpointOutputOptions)
- func AddPodHttpMultipleEndpointOutput(options AddPodHttpEndpointsOutputOptions)
- func AddPreviousLogs(cfg *config.Config, path string, namespace string, name string)
- func AddResourceUsage(cfg *config.Config, path string, namespace string, name string, executions int)
- func DownloadFromPod(options AddDownloadOutputOptions)
- func FindDeployment(cfg *config.Config, namespace string, name string) (*appsv1.Deployment, error)
- func FindStatefulSet(cfg *config.Config, namespace string, name string) (*appsv1.StatefulSet, error)
- func ForEachNode(cfg *config.Config, fn func(node *v1.Node))
- func ForEachPod(cfg *config.Config, namespace string, selector *metav1.LabelSelector, ...)
- func ForEachPodViaMapSelector(cfg *config.Config, namespace string, selectorMap map[string]string, ...)
- func KillProcess(cmd *exec.Cmd, options PodConfig)
- func PreparePortforwarding(options PodConfig, port int) (string, *exec.Cmd, error)
- type AddDownloadOutputOptions
- type AddPodHttpEndpointOutputOptions
- type AddPodHttpEndpointsOutputOptions
- type Connection
- type ConnectionTester
- func (t *ConnectionTester) AddExtensionConnectionTest(outputPath string, connection Connection)
- func (t *ConnectionTester) AddPlatformConnectionTest(outputPath string, url string)
- func (t *ConnectionTester) AddWebsocketConnectionTest(outputPath string, url string)
- func (t *ConnectionTester) AddWebsocketCurlHttp1ConnectionTest(outputPath string, url string)
- func (t *ConnectionTester) AddWebsocketCurlHttp2ConnectionTest(outputPath string, url string)
- type EndpointsOutputOptions
- type PodConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddDescription ¶
func AddKubernetesNodesInformation ¶ added in v1.0.0
func AddPodHttpEndpointOutput ¶
func AddPodHttpEndpointOutput(options AddPodHttpEndpointOutputOptions)
func AddPodHttpMultipleEndpointOutput ¶ added in v1.1.2
func AddPodHttpMultipleEndpointOutput(options AddPodHttpEndpointsOutputOptions)
func AddPreviousLogs ¶
func AddResourceUsage ¶
func AddResourceUsage(cfg *config.Config, path string, namespace string, name string, executions int)
AddResourceUsage path must include '%d' to replace the execution number within the file path
func DownloadFromPod ¶ added in v1.1.2
func DownloadFromPod(options AddDownloadOutputOptions)
func FindDeployment ¶
func FindStatefulSet ¶ added in v1.2.0
func ForEachNode ¶ added in v1.0.0
ForEachNode note that the function fn will be executed in parallel for each node
func ForEachPod ¶
func ForEachPod(cfg *config.Config, namespace string, selector *metav1.LabelSelector, fn func(pod *v1.Pod, idx int))
ForEachPod note that the function fn will be executed in parallel for each pod
func ForEachPodViaMapSelector ¶ added in v1.1.2
func ForEachPodViaMapSelector(cfg *config.Config, namespace string, selectorMap map[string]string, fn func(pod *v1.Pod, idx int))
ForEachPodViaMapSelector note that the function fn will be executed in parallel for each pod
func KillProcess ¶ added in v1.1.2
func PreparePortforwarding ¶ added in v1.1.2
PreparePortforwarding deliberately does not acquire limit.Commands: the port-forward stays alive while the requests through it run, so it would block the very executions it exists for. Its callers run within a limit.Items slot, which is what bounds the number of concurrent port-forwards.
Types ¶
type AddDownloadOutputOptions ¶ added in v1.1.2
type AddPodHttpEndpointsOutputOptions ¶ added in v1.1.2
type AddPodHttpEndpointsOutputOptions struct {
PodConfig PodConfig
EndpointOptions []EndpointsOutputOptions
}
type Connection ¶ added in v1.2.4
func GetExtensionConnections ¶ added in v1.2.4
func GetExtensionConnections(sharedPort int, podConfig PodConfig, cfg *config.Config) []Connection
type ConnectionTester ¶ added in v1.4.0
type ConnectionTester struct {
// contains filtered or unexported fields
}
ConnectionTester runs the connection tests of one pod from inside that pod. Tests sharing an image also share the ephemeral container they are executed in: starting one costs seconds, and since Kubernetes never removes it from the pod again, one container per test would both slow the run down and leave a long trail behind.
func NewConnectionTester ¶ added in v1.4.0
func (*ConnectionTester) AddExtensionConnectionTest ¶ added in v1.4.0
func (t *ConnectionTester) AddExtensionConnectionTest(outputPath string, connection Connection)
AddExtensionConnectionTest reaches an extension the way the agent reaches it, which for a setup using mutual TLS means presenting the agent's client certificate - without it the extension rejects the request and the test says nothing about whether the agent itself can get through.
func (*ConnectionTester) AddPlatformConnectionTest ¶ added in v1.4.0
func (t *ConnectionTester) AddPlatformConnectionTest(outputPath string, url string)
AddPlatformConnectionTest reaches the platform the way the agent reaches it. Without the agent key the platform answers 401 to everything, so the test asks twice: once verbosely and anonymously, for the connection itself, and once with the key to find out whether it is accepted.
func (*ConnectionTester) AddWebsocketConnectionTest ¶ added in v1.4.0
func (t *ConnectionTester) AddWebsocketConnectionTest(outputPath string, url string)
AddWebsocketConnectionTest opens an actual websocket, which validates the handshake beyond the plain upgrade the tests above send: curl checks the server's sec-websocket-accept before switching protocols.
func (*ConnectionTester) AddWebsocketCurlHttp1ConnectionTest ¶ added in v1.4.0
func (t *ConnectionTester) AddWebsocketCurlHttp1ConnectionTest(outputPath string, url string)
func (*ConnectionTester) AddWebsocketCurlHttp2ConnectionTest ¶ added in v1.4.0
func (t *ConnectionTester) AddWebsocketCurlHttp2ConnectionTest(outputPath string, url string)