create jobs queue for scheduling new builds
This commit is contained in:
parent
7df735e36b
commit
0861b80c99
5 changed files with 150 additions and 9 deletions
|
|
@ -11,6 +11,7 @@ import (
|
|||
"os/signal"
|
||||
"path/filepath"
|
||||
|
||||
"osbuild-composer/internal/queue"
|
||||
"osbuild-composer/internal/rpmmd"
|
||||
"osbuild-composer/internal/weldr"
|
||||
)
|
||||
|
|
@ -59,7 +60,8 @@ func main() {
|
|||
}
|
||||
|
||||
stateChannel := make(chan []byte, 10)
|
||||
api := weldr.New(repo, packages, logger, state, stateChannel)
|
||||
buildChannel := make(chan queue.Build, 200)
|
||||
api := weldr.New(repo, packages, logger, state, stateChannel, buildChannel)
|
||||
go func() {
|
||||
for {
|
||||
err := writeFileAtomically(StateFile, <-stateChannel, 0755)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue