Documentation ¶
Overview ¶
Package check provides set of checks to verify cluster readiness.
Package check provides set of checks to verify cluster readiness.
Package check provides set of checks to verify cluster readiness.
Package check provides set of checks to verify cluster readiness.
Index ¶
- func ApidReadyAssertion(ctx context.Context, cluster provision.ClusterAccess) error
- func K8sAllNodesReadyAssertion(ctx context.Context, cluster provision.ClusterAccess) error
- func K8sAllNodesReportedAssertion(ctx context.Context, cluster provision.ClusterAccess) error
- func K8sFullControlPlaneAssertion(ctx context.Context, cluster provision.ClusterAccess) error
- func K8sPodReadyAssertion(ctx context.Context, cluster provision.ClusterAccess, ...) error
- func ServiceHealthAssertion(ctx context.Context, cluster provision.ClusterAccess, service string, ...) error
- func ServiceStateAssertion(ctx context.Context, cluster provision.ClusterAccess, service, state string) error
- func Wait(ctx context.Context, cluster provision.ClusterAccess, checks []ClusterCheck, ...) error
- type ClusterCheck
- type Option
- type Options
- type Reporter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ApidReadyAssertion ¶
func ApidReadyAssertion(ctx context.Context, cluster provision.ClusterAccess) error
ApidReadyAssertion checks whether apid is responsive on all the nodes.
func K8sAllNodesReadyAssertion ¶
func K8sAllNodesReadyAssertion(ctx context.Context, cluster provision.ClusterAccess) error
K8sAllNodesReadyAssertion checks whether all the nodes are Ready.
func K8sAllNodesReportedAssertion ¶
func K8sAllNodesReportedAssertion(ctx context.Context, cluster provision.ClusterAccess) error
K8sAllNodesReportedAssertion checks whether all the nodes show up in node list.
func K8sFullControlPlaneAssertion ¶
func K8sFullControlPlaneAssertion(ctx context.Context, cluster provision.ClusterAccess) error
K8sFullControlPlaneAssertion checks whether all the master nodes are k8s master nodes.
nolint: gocyclo
func K8sPodReadyAssertion ¶
func K8sPodReadyAssertion(ctx context.Context, cluster provision.ClusterAccess, namespace, labelSelector string) error
K8sPodReadyAssertion checks whether all the nodes are Ready.
func ServiceHealthAssertion ¶
func ServiceHealthAssertion(ctx context.Context, cluster provision.ClusterAccess, service string, setters ...Option) error
ServiceHealthAssertion checks whether service reached some specified state. nolint: gocyclo
func ServiceStateAssertion ¶
func ServiceStateAssertion(ctx context.Context, cluster provision.ClusterAccess, service, state string) error
ServiceStateAssertion checks whether service reached some specified state.
func Wait ¶
func Wait(ctx context.Context, cluster provision.ClusterAccess, checks []ClusterCheck, reporter Reporter) error
Wait run the checks against the cluster and waits for the full set to succeed.
Context ctx might have a timeout set to limit overall wait time. Each check might define its own timeout.
Types ¶
type ClusterCheck ¶
type ClusterCheck func(provision.ClusterAccess) conditions.Condition
ClusterCheck implements a function which returns condition based on ClusterAccess.
func DefaultClusterChecks ¶
func DefaultClusterChecks() []ClusterCheck
DefaultClusterChecks returns a set of default Talos cluster readiness checks.
type Option ¶
Option represents functional option.
func WithNodeTypes ¶
WithNodeTypes sets the node types for a check.
type Reporter ¶
type Reporter interface {
Update(check conditions.Condition)
}
Reporter presents wait progress.
It is supposed that reporter drops duplicate messages.
func StderrReporter ¶
func StderrReporter() Reporter
StderrReporter returns console reporter with stderr output.