debian-forge-composer/internal/osbuildexecutor/runner-impl-host.go
Sanne Raymaekers e10424de2f 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.
2024-02-14 09:54:11 +01:00

18 lines
478 B
Go

package osbuildexecutor
import (
"io"
"github.com/osbuild/images/pkg/osbuild"
)
type hostExecutor struct{}
func (he *hostExecutor) RunOSBuild(manifest []byte, store, outputDirectory string, exports, checkpoints,
extraEnv []string, result bool, errorWriter io.Writer) (*osbuild.Result, error) {
return osbuild.RunOSBuild(manifest, store, outputDirectory, exports, checkpoints, extraEnv, result, errorWriter)
}
func NewHostExecutor() Executor {
return &hostExecutor{}
}