Utilize containerized kernel and remove kernel Support

This commit is contained in:
Gregory Kurtzer
2022-02-15 06:49:24 +00:00
parent 2003ad8768
commit 5a0c13225e
27 changed files with 73 additions and 668 deletions

View File

@@ -3,10 +3,10 @@ package list
import (
"fmt"
"os"
"path"
"github.com/hpcng/warewulf/internal/pkg/container"
"github.com/hpcng/warewulf/internal/pkg/node"
"github.com/hpcng/warewulf/internal/pkg/util"
"github.com/hpcng/warewulf/internal/pkg/wwlog"
"github.com/spf13/cobra"
)
@@ -27,14 +27,14 @@ func CobraRunE(cmd *cobra.Command, args []string) error {
nodemap[n.ContainerName.Get()]++
}
fmt.Printf("%-35s %-6s %-6s\n", "CONTAINER NAME", "BUILT", "NODES")
fmt.Printf("%-25s %-6s %-6s\n", "CONTAINER NAME", "NODES", "KERNEL")
for _, source := range sources {
image := container.ImageFile(source)
if nodemap[source] == 0 {
nodemap[source] = 0
}
fmt.Printf("%-35s %-6t %-6d\n", source, util.IsFile(image), nodemap[source])
kernel := container.KernelFind(source)
fmt.Printf("%-25s %-6d %s\n", source, nodemap[source], path.Base(kernel))
}
return nil