osbuildexecutor: introduce osbuildexecutor.Executor interface
Wrap the current osbuildexecutor.Executor in an interface so it's easier to add different executors, which for instance can run osbuild in a VM.
This commit is contained in:
parent
9e85050633
commit
e10424de2f
4 changed files with 51 additions and 3 deletions
11
internal/osbuildexecutor/osbuild-executor.go
Normal file
11
internal/osbuildexecutor/osbuild-executor.go
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
package osbuildexecutor
|
||||
|
||||
import (
|
||||
"io"
|
||||
|
||||
"github.com/osbuild/images/pkg/osbuild"
|
||||
)
|
||||
|
||||
type Executor interface {
|
||||
RunOSBuild(manifest []byte, store, outputDirectory string, exports, checkpoints, extraEnv []string, result bool, errorWriter io.Writer) (*osbuild.Result, error)
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue