Skip to content

Commit 281f446

Browse files
committed
kubeadm: log more information when missing the necessary config element
Signed-off-by: SataQiu <[email protected]>
1 parent 61f0036 commit 281f446

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cmd/kubeadm/app/util/marshal.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ func SplitYAMLDocuments(yamlBytes []byte) (kubeadmapi.DocumentMap, error) {
9797
return nil, err
9898
}
9999
if len(gvk.Group) == 0 || len(gvk.Version) == 0 || len(gvk.Kind) == 0 {
100-
return nil, errors.New("invalid configuration: kind and apiVersion is mandatory information that needs to be specified")
100+
return nil, errors.Errorf("invalid configuration for GroupVersionKind %+v: kind and apiVersion is mandatory information that must be specified", gvk)
101101
}
102102

103103
// Check whether the kind has been registered before. If it has, throw an error

0 commit comments

Comments
 (0)