File tree Expand file tree Collapse file tree 6 files changed +37
-4
lines changed Expand file tree Collapse file tree 6 files changed +37
-4
lines changed File renamed without changes.
Original file line number Diff line number Diff line change 1212in
1313 with lib ; {
1414 imports = [
15+ # Common host level config (also applied at guest level)
16+ ./common.nix
1517 # GC only from the host to avoid duplicating GC in containers
1618 ./auto-gc.nix
1719 # Docker module required in both the host and guest containers
127129
128130 config = {
129131 imports = [
132+ # Common guest level config (also applied at host level)
130133 ./common.nix
134+
135+ # Prevent nix sandbox related failures
131136 ./nix_nsswitch.nix
132137
133138 # Docker module required in both the host and guest containers
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change @@ -508,10 +508,38 @@ in {
508508 ++ ( baseEquinixMachineConfig "equinix-1" )
509509 ++ buildkiteOnly
510510 ++ [
511- ./buildkite-agent-containers.nix
512- ./common.nix
513- ( { lib , ...} : {
514- } )
511+ ./buildkite/buildkite-agent-containers.nix
512+ (
513+ {
514+ config ,
515+ lib ,
516+ ...
517+ } : let
518+ cfg = config . services . buildkite-containers ;
519+ in {
520+ services . auto-gc = {
521+ nixAutoMaxFreedGB = 150 ;
522+ nixAutoMinFreeGB = 90 ;
523+ nixHourlyMaxFreedGB = 600 ;
524+ nixHourlyMinFreeGB = 150 ;
525+ nixWeeklyGcFull = true ;
526+ nixWeeklyGcOnCalendar = "Sat *-*-* 20:00:00" ;
527+ } ;
528+
529+ services . buildkite-containers . containerList = let
530+ mkContainer = n : prio : {
531+ containerName = "ci${ cfg . hostIdSuffix } -${ toString n } " ;
532+ guestIp = "10.254.1.1${ toString n } " ;
533+ inherit prio ;
534+ tags = {
535+ system = "x86_64-linux" ;
536+ queue = "test" ;
537+ } ;
538+ } ;
539+ in
540+ map ( n : mkContainer n ( toString ( 10 - n ) ) ) ( lib . range 1 5 ) ;
541+ }
542+ )
515543 ] ;
516544 } ;
517545 } ;
You can’t perform that action at this time.
0 commit comments