osbuild: add extraEnv argument to RunOSBuild
This adds the ability to supply extra environment variables to the osbuild process.
This commit is contained in:
parent
31072c1189
commit
2c0594629f
3 changed files with 8 additions and 3 deletions
|
|
@ -55,7 +55,7 @@ func RunPlayground(img image.ImageKind, d distro.Distro, arch distro.Arch, repos
|
|||
|
||||
store := path.Join(state_dir, "osbuild-store")
|
||||
|
||||
_, err = osbuild.RunOSBuild(bytes, store, "./", manifest.GetExports(), manifest.GetCheckpoints(), false, os.Stdout)
|
||||
_, err = osbuild.RunOSBuild(bytes, store, "./", manifest.GetExports(), manifest.GetCheckpoints(), nil, false, os.Stdout)
|
||||
if err != nil {
|
||||
fmt.Fprintf(os.Stderr, "could not run osbuild: %s", err.Error())
|
||||
}
|
||||
|
|
|
|||
|
|
@ -307,7 +307,7 @@ func (impl *OSBuildJobImpl) Run(job worker.Job) error {
|
|||
}
|
||||
|
||||
// Run osbuild and handle two kinds of errors
|
||||
osbuildJobResult.OSBuildOutput, err = osbuild.RunOSBuild(jobArgs.Manifest, impl.Store, outputDirectory, exports, nil, true, os.Stderr)
|
||||
osbuildJobResult.OSBuildOutput, err = osbuild.RunOSBuild(jobArgs.Manifest, impl.Store, outputDirectory, exports, nil, nil, true, os.Stderr)
|
||||
// First handle the case when "running" osbuild failed
|
||||
if err != nil {
|
||||
osbuildJobResult.JobError = clienterrors.WorkerClientError(clienterrors.ErrorBuildJob, "osbuild build failed")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue