Documentation ¶
Index ¶
- func Connected(clusterObj APIClientGetter) (bool, error)
- func Disconnected(clusterObj APIClientGetter) (bool, error)
- func ExecCmd(apiClient *clients.Settings, nodeSelector string, shellCmd string) error
- func ExecCmdWithRetries(client *clients.Settings, retries uint, interval time.Duration, ...) error
- func ExecCmdWithStdout(apiClient *clients.Settings, shellCmd string, options ...metav1.ListOptions) (map[string]string, error)
- func ExecCmdWithStdoutWithRetries(client *clients.Settings, retries uint, interval time.Duration, command string, ...) (map[string]string, error)
- func ExecCommandOnSNOWithRetries(client *clients.Settings, retries uint, interval time.Duration, command string) (string, error)
- func GetOCPClusterName(clusterObj APIClientGetter) (string, error)
- func GetOCPClusterVersion(clusterObj APIClientGetter) (*clusterversion.Builder, error)
- func GetOCPNetworkConfig(clusterObj APIClientGetter) (*network.ConfigBuilder, error)
- func GetOCPNetworkOperatorConfig(clusterObj APIClientGetter) (*network.OperatorBuilder, error)
- func GetOCPProxy(clusterObj APIClientGetter) (*proxy.Builder, error)
- func GetOCPPullSecret(clusterObj APIClientGetter) (*secret.Builder, error)
- func PullTestImageOnNodes(apiClient *clients.Settings, nodeSelector, image string, pullTimeout int) error
- func SoftRebootSNO(apiClient *clients.Settings, retries uint, interval time.Duration) error
- func WaitForRecover(client *clients.Settings, namespaces []string, timeout time.Duration) error
- func WaitForUnreachable(client *clients.Settings, timeout time.Duration) error
- type APIClientGetter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Connected ¶
func Connected(clusterObj APIClientGetter) (bool, error)
Connected checks that the OCP cluster of the provided client is connected.
func Disconnected ¶
func Disconnected(clusterObj APIClientGetter) (bool, error)
Disconnected checks that the OCP cluster of the provided client is disconnected.
func ExecCmdWithRetries ¶
func ExecCmdWithRetries(client *clients.Settings, retries uint, interval time.Duration, nodeSelector, command string) error
ExecCmdWithRetries executes a command on the provided client on each node matching nodeSelector, retrying on internal errors "retries" times with a "interval" duration between retries, and ignores the stdout.
func ExecCmdWithStdout ¶
func ExecCmdWithStdout( apiClient *clients.Settings, shellCmd string, options ...metav1.ListOptions) (map[string]string, error)
ExecCmdWithStdout runs cmd on all selected nodes and returns their stdout.
func ExecCmdWithStdoutWithRetries ¶
func ExecCmdWithStdoutWithRetries( client *clients.Settings, retries uint, interval time.Duration, command string, options ...metav1.ListOptions) (map[string]string, error)
ExecCmdWithStdoutWithRetries executes a command on the provided client, retrying on internal errors "retries" times with a "interval" duration between retries, and returns the stdout for each node.
func ExecCommandOnSNOWithRetries ¶
func ExecCommandOnSNOWithRetries(client *clients.Settings, retries uint, interval time.Duration, command string) (string, error)
ExecCommandOnSNOWithRetries executes a command on the provided single node client, retrying on internal errors "retries" times waits with a "interval" duration between retries, and returns the stdout.
func GetOCPClusterName ¶
func GetOCPClusterName(clusterObj APIClientGetter) (string, error)
GetOCPClusterName retrieves the OCP cluster name from an arbitrary cluster.
func GetOCPClusterVersion ¶
func GetOCPClusterVersion(clusterObj APIClientGetter) (*clusterversion.Builder, error)
GetOCPClusterVersion leverages APIClientGetter to retrieve the OCP clusterversion from an arbitrary cluster.
func GetOCPNetworkConfig ¶
func GetOCPNetworkConfig(clusterObj APIClientGetter) (*network.ConfigBuilder, error)
GetOCPNetworkConfig leverages APIClientGetter to retrieve the OCP cluster network from an arbitrary cluster.
func GetOCPNetworkOperatorConfig ¶
func GetOCPNetworkOperatorConfig(clusterObj APIClientGetter) (*network.OperatorBuilder, error)
GetOCPNetworkOperatorConfig leverages APIClientGetter to retrieve the OCP cluster network from an arbitrary cluster.
func GetOCPProxy ¶
func GetOCPProxy(clusterObj APIClientGetter) (*proxy.Builder, error)
GetOCPProxy leverages APIClientGetter to retrieve the OCP cluster proxy from an arbitrary cluster.
func GetOCPPullSecret ¶
func GetOCPPullSecret(clusterObj APIClientGetter) (*secret.Builder, error)
GetOCPPullSecret leverages APIClientGetter to retrieve the OCP pull-secret from an arbitrary cluster.
func PullTestImageOnNodes ¶
func PullTestImageOnNodes(apiClient *clients.Settings, nodeSelector, image string, pullTimeout int) error
PullTestImageOnNodes pulls given image on range of relevant nodes based on nodeSelector.
func SoftRebootSNO ¶
SoftRebootSNO executes systemctl reboot on a node.
func WaitForRecover ¶
WaitForRecover waits up to timeout for all pods in namespaces on a provided node to recover.
Types ¶
type APIClientGetter ¶
APIClientGetter is an interface that returns an APIClient from a struct.