osbuild2: NewLVM2MetadataStage takes map of devices
Instead of just passing in a single device, pass in a `Devices` type, i.e. a map of devices, since the LVM can be located on a LUKS2 container which is located inside a partition so multiple devices are needed to access it. Co-Authored-By: Achilleas Koutsou <achilleas@koutsou.net>
This commit is contained in:
parent
d48d6f22e1
commit
2314ca37d7
1 changed files with 2 additions and 2 deletions
|
|
@ -33,7 +33,7 @@ func (o LVM2MetadataStageOptions) validate() error {
|
|||
return nil
|
||||
}
|
||||
|
||||
func NewLVM2MetadataStage(options *LVM2MetadataStageOptions, device *Device) *Stage {
|
||||
func NewLVM2MetadataStage(options *LVM2MetadataStageOptions, devices Devices) *Stage {
|
||||
if err := options.validate(); err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
|
@ -41,6 +41,6 @@ func NewLVM2MetadataStage(options *LVM2MetadataStageOptions, device *Device) *St
|
|||
return &Stage{
|
||||
Type: "org.osbuild.lvm2.metadata",
|
||||
Options: options,
|
||||
Devices: Devices{"device": *device},
|
||||
Devices: devices,
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue