osbuild2/copy: ctor helper with only inputs
Add a simple constructor helper function that does not have mounts and devices but only inputs.
This commit is contained in:
parent
8970cdfd83
commit
6e70506903
1 changed files with 12 additions and 0 deletions
|
|
@ -46,3 +46,15 @@ func NewCopyStage(options *CopyStageOptions, inputs CopyStageInputsNew, devices
|
|||
Mounts: *mounts,
|
||||
}
|
||||
}
|
||||
|
||||
func NewCopyStageSimple(options *CopyStageOptions, inputs CopyStageInputsNew) *Stage {
|
||||
var stageInputs Inputs
|
||||
if inputs != nil {
|
||||
stageInputs = inputs.(Inputs)
|
||||
}
|
||||
return &Stage{
|
||||
Type: "org.osbuild.copy",
|
||||
Options: options,
|
||||
Inputs: stageInputs,
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue