1
0

feat: add container volumes list function

This commit is contained in:
dump_stack() 2023-05-14 22:15:43 +00:00
parent 1b2d636410
commit b2383ba442
Signed by: dump_stack
GPG Key ID: BE44DA8C062D87DC

View File

@ -291,3 +291,13 @@ func ContainerKernels(d container.Image, kcfg *config.KernelConfig) (err error)
return
}
func ContainerVolumes(pkgname, contname string) (volumes container.Volumes) {
pkgdir := filepath.Join("volumes", contname, pkgname)
volumes.LibModules = config.Dir(pkgdir, "/lib/modules")
volumes.UsrSrc = config.Dir(pkgdir, "/usr/src")
volumes.Boot = config.Dir(pkgdir, "/boot")
return
}