Skip to content

Commit

Permalink
Exit early if node name is not provided in CLI (#895)
Browse files Browse the repository at this point in the history
  • Loading branch information
bschimke95 authored Dec 12, 2024
1 parent 79937d2 commit c0f3b07
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/k8s/cmd/k8s/k8s_get_join_token.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ func newGetJoinTokenCmd(env cmdutil.ExecutionEnvironment) *cobra.Command {
Run: func(cmd *cobra.Command, args []string) {
if !opts.worker && len(args) == 0 {
cmd.PrintErrln("Error: A node name is required for control-plane nodes.")
env.Exit(1)
return
}

var name string
Expand Down

0 comments on commit c0f3b07

Please sign in to comment.