job/osbuild: skip the job if manifest generation failed

Running the job in this case is basically undefined, so let's just skip it
in order to not break anything.

Signed-off-by: Ondřej Budai <ondrej@budai.cz>
This commit is contained in:
Ondřej Budai 2021-11-16 08:32:24 +01:00 committed by Tom Gundersen
parent 0508a7ad1b
commit c56eb724e8

View file

@ -92,6 +92,11 @@ func (impl *OSBuildJobImpl) Run(job worker.Job) error {
if err != nil {
return err
}
// skip the job if the manifest generation failed
if manifestJR.Error != "" {
return nil
}
args.Manifest = manifestJR.Manifest
}
// copy pipeline info to the result