diff options
Diffstat (limited to 'nixos/modules')
-rw-r--r-- | nixos/modules/services/continuous-integration/buildbot/master.nix | 18 | ||||
-rw-r--r-- | nixos/modules/services/continuous-integration/buildbot/worker.nix | 5 |
2 files changed, 7 insertions, 16 deletions
diff --git a/nixos/modules/services/continuous-integration/buildbot/master.nix b/nixos/modules/services/continuous-integration/buildbot/master.nix index f638cf4bae3..68306109130 100644 --- a/nixos/modules/services/continuous-integration/buildbot/master.nix +++ b/nixos/modules/services/continuous-integration/buildbot/master.nix @@ -28,7 +28,7 @@ let ${cfg.extraConfig} '' - else pkgs.writeText "master.cfg" cfg.masterCfg; + else cfg.masterCfg; in { options = { @@ -66,13 +66,10 @@ in { }; masterCfg = mkOption { - type = types.nullOr types.str; - description = '' - Optionally pass raw master.cfg file as string. - Other options in this configuration will be ignored. - ''; + type = types.nullOr types.path; + description = "Optionally pass master.cfg path. Other options in this configuration will be ignored."; default = null; - example = "BuildmasterConfig = c = {}"; + example = "/etc/nixos/buildbot/master.cfg"; }; schedulers = mkOption { @@ -88,7 +85,7 @@ in { type = types.listOf types.str; description = "List of Builders."; default = [ - "util.BuilderConfig(name='runtests',workernames=['default-worker'],factory=factory)" + "util.BuilderConfig(name='runtests',workernames=['example-worker'],factory=factory)" ]; }; @@ -183,10 +180,7 @@ in { package = mkOption { type = types.package; default = pkgs.buildbot-ui; - description = '' - Package to use for buildbot. - <literal>buildbot-full</literal> is required in order to use local workers. - ''; + description = "Package to use for buildbot."; example = pkgs.buildbot-full; }; diff --git a/nixos/modules/services/continuous-integration/buildbot/worker.nix b/nixos/modules/services/continuous-integration/buildbot/worker.nix index 430fd4e53f1..1ad1319d501 100644 --- a/nixos/modules/services/continuous-integration/buildbot/worker.nix +++ b/nixos/modules/services/continuous-integration/buildbot/worker.nix @@ -100,14 +100,11 @@ in { systemd.services.buildbot-worker = { description = "Buildbot Worker."; - after = [ "network.target" ]; + after = [ "network.target" "buildbot-master.service" ]; wantedBy = [ "multi-user.target" ]; - wants = [ "buildbot-master.service" ]; path = cfg.packages; preStart = '' - # NOTE: ensure master has time to start in case running on localhost - ${pkgs.coreutils}/bin/sleep 4 ${pkgs.coreutils}/bin/mkdir -vp ${cfg.buildbotDir} ${cfg.package}/bin/buildbot-worker create-worker ${cfg.buildbotDir} ${cfg.masterUrl} ${cfg.workerUser} ${cfg.workerPass} ''; |