mirror of
https://github.com/linka-cloud/d2vm.git
synced 2025-12-14 15:03:12 +00:00
add split boot partiton support
Signed-off-by: Adphi <philippe.adrien.nousse@gmail.com>
This commit is contained in:
@@ -17,15 +17,18 @@ package d2vm
|
||||
type ConvertOption func(o *convertOptions)
|
||||
|
||||
type convertOptions struct {
|
||||
size int64
|
||||
size uint64
|
||||
password string
|
||||
output string
|
||||
cmdLineExtra string
|
||||
networkManager NetworkManager
|
||||
raw bool
|
||||
|
||||
splitBoot bool
|
||||
bootSize uint64
|
||||
}
|
||||
|
||||
func WithSize(size int64) ConvertOption {
|
||||
func WithSize(size uint64) ConvertOption {
|
||||
return func(o *convertOptions) {
|
||||
o.size = size
|
||||
}
|
||||
@@ -60,3 +63,15 @@ func WithRaw(raw bool) ConvertOption {
|
||||
o.raw = raw
|
||||
}
|
||||
}
|
||||
|
||||
func WithSplitBoot(b bool) ConvertOption {
|
||||
return func(o *convertOptions) {
|
||||
o.splitBoot = b
|
||||
}
|
||||
}
|
||||
|
||||
func WithBootSize(bootSize uint64) ConvertOption {
|
||||
return func(o *convertOptions) {
|
||||
o.bootSize = bootSize
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user