Skip to content

Commit

Permalink
Merge pull request #322 from HarrisonWAffel/update-add-nodes-details-…
Browse files Browse the repository at this point in the history
…38515

Update error messages and usage for add-node command
  • Loading branch information
HarrisonWAffel authored Aug 31, 2022
2 parents 2fcf307 + 142054b commit 2144a4c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cmd/cluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ func ClusterCommand() cli.Command {
},
{
Name: "add-node",
Usage: "Outputs the docker command needed to add a node to an existing Rancher cluster",
Usage: "Outputs the docker command needed to add a node to an existing Rancher custom cluster",
ArgsUsage: "[CLUSTERID CLUSTERNAME]",
Action: clusterAddNode,
Flags: []cli.Flag{
Expand Down Expand Up @@ -353,10 +353,10 @@ func clusterAddNode(ctx *cli.Context) error {
}

if len(nodePools.Data) > 0 {
return errors.New("a node can't be added to the cluster this way")
return errors.New("a node can't be manually registered to a cluster utilizing node-pools")
}
} else {
return errors.New("a node can't be added to the cluster this way")
return errors.New("a node can only be manually registered to a custom cluster")
}

clusterToken, err := getClusterRegToken(ctx, c, cluster.ID)
Expand Down

0 comments on commit 2144a4c

Please sign in to comment.