worker: introduce dynamicArgs

In addition to the arguments passed when scheduling a job, a job now
also takes the results of its dependencies as additional arguments. We
call these dynamic arguments for the lack of a better term.

The immediate use-case for this is to allow koji jobs to be split up
as follows:
 - koji-init: Creates a koji build, and returns us a token.
 - osbuild-koji: one job per architecture, depending on koji-init
   having succeeded. Builds the image, and uploads it to koji,
   returning metadata about the image produced.
 - koji-finalize: uses the token from koji-init and the metadata
   from osbuild-koji to import the build into koji if it succeeded
   or mark it as failed if it failed.
This commit is contained in:
Tom Gundersen 2020-11-06 17:06:36 +00:00 committed by Lars Karlitski
parent 11d0da0b5c
commit a2895376ae
5 changed files with 26 additions and 12 deletions

View file

@ -63,6 +63,9 @@ paths:
enum:
- osbuild
args: {}
dynamic_args:
type: array
items: {}
required:
- type
- location