This commit is contained in:
parent
c1adf1a517
commit
76c59221d1
2 changed files with 3 additions and 7 deletions
|
@ -2,7 +2,7 @@ job "builder" {
|
||||||
namespace = "ci"
|
namespace = "ci"
|
||||||
type = "batch"
|
type = "batch"
|
||||||
|
|
||||||
datacenters = ["neptune", "jupiter", "corrin", "bespin"]
|
datacenters = ["bespin", "corrin"]
|
||||||
priority = 100
|
priority = 100
|
||||||
|
|
||||||
parameterized {
|
parameterized {
|
||||||
|
@ -57,6 +57,7 @@ fi
|
||||||
|
|
||||||
task "executor" {
|
task "executor" {
|
||||||
driver = "docker"
|
driver = "docker"
|
||||||
|
leader = true
|
||||||
config {
|
config {
|
||||||
image = "nixpkgs/nix:nixos-22.11"
|
image = "nixpkgs/nix:nixos-22.11"
|
||||||
args = [ "/tmp/builder.sh" ]
|
args = [ "/tmp/builder.sh" ]
|
||||||
|
@ -162,11 +163,6 @@ experimental-features = nix-command flakes
|
||||||
cpu = 1000
|
cpu = 1000
|
||||||
memory = 4000
|
memory = 4000
|
||||||
}
|
}
|
||||||
|
|
||||||
lifecycle {
|
|
||||||
hook = "prestart"
|
|
||||||
sidecar = true
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
2
main.go
2
main.go
|
@ -302,7 +302,7 @@ func build(w http.ResponseWriter, r *http.Request) {
|
||||||
|
|
||||||
allocFS := NomadClient.AllocFS()
|
allocFS := NomadClient.AllocFS()
|
||||||
scancel := make(chan struct{})
|
scancel := make(chan struct{})
|
||||||
sframe, serr := allocFS.Logs(myAlloc, true, "runner", logFilter, "start", 0, scancel, &nomad.QueryOptions{})
|
sframe, serr := allocFS.Logs(myAlloc, true, "executor", logFilter, "start", 0, scancel, &nomad.QueryOptions{})
|
||||||
|
|
||||||
// stream logs to client's browser
|
// stream logs to client's browser
|
||||||
build_loop:
|
build_loop:
|
||||||
|
|
Loading…
Reference in a new issue