worker/RequestJob: treat 'osbuild-koji' jobs like 'osbuild' ones
We must special-case the treatment of architecture, to select the correct remote worker for any job that requires a specific architecture. For now this means any jobs that run osbuild.
This commit is contained in:
parent
0e382e9cf4
commit
79f87ea347
1 changed files with 4 additions and 2 deletions
|
|
@ -176,8 +176,8 @@ func (s *Server) RequestJob(ctx context.Context, arch string, jobTypes []string)
|
|||
// restriction: arch for osbuild jobs.
|
||||
jts := []string{}
|
||||
for _, t := range jobTypes {
|
||||
if t == "osbuild" {
|
||||
t = "osbuild:" + arch
|
||||
if t == "osbuild" || t == "osbuild-koji" {
|
||||
t = t + ":" + arch
|
||||
}
|
||||
jts = append(jts, t)
|
||||
}
|
||||
|
|
@ -206,6 +206,8 @@ func (s *Server) RequestJob(ctx context.Context, arch string, jobTypes []string)
|
|||
|
||||
if jobType == "osbuild:"+arch {
|
||||
jobType = "osbuild"
|
||||
} else if jobType == "osbuild-koji:"+arch {
|
||||
jobType = "osbuild-koji"
|
||||
}
|
||||
|
||||
return token, jobId, jobType, args, dynamicArgs, nil
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue