fix: improve error message on single node upgrade

Fixes: https://github.com/siderolabs/talos/issues/6828

Propose a solution if the node upgrade fails.

Signed-off-by: Artem Chernyshev <artem.chernyshev@talos-systems.com>
This commit is contained in:
Artem Chernyshev 2023-02-16 17:31:52 +03:00
parent ed5af3f780
commit dcd4eb1a93
No known key found for this signature in database
GPG Key ID: 9B9D0328B57B443F

View File

@ -98,7 +98,7 @@ func (c *Client) ValidateForUpgrade(ctx context.Context, config config.Provider,
if !preserve {
if len(resp.Members) == 1 {
return fmt.Errorf("only 1 etcd member found. assuming this is not an HA setup and refusing to upgrade")
return fmt.Errorf("only 1 etcd member found; assuming this is not an HA setup and refusing to upgrade; if this is a single-node cluster, use --preserve to upgrade")
}
}