default profile needs to have a container

Signed-off-by: Christian Goll <cgoll@suse.com>
This commit is contained in:
Christian Goll
2023-07-19 11:28:49 +02:00
committed by Jonathon Anderson
parent a36cb23319
commit 2fe98e5f55
9 changed files with 125 additions and 7 deletions

View File

@@ -5,6 +5,7 @@ import (
"os"
"github.com/hpcng/warewulf/internal/pkg/node"
"github.com/hpcng/warewulf/internal/pkg/util"
"github.com/hpcng/warewulf/internal/pkg/wwlog"
"github.com/manifoldco/promptui"
"github.com/pkg/errors"
@@ -13,6 +14,9 @@ import (
func CobraRunE(cmd *cobra.Command, args []string) error {
var count int
if util.InSlice(args, "default") {
return fmt.Errorf("can't delete the `default` profile ")
}
nodeDB, err := node.New()
if err != nil {