Commit f8be2c43 authored by Jörg Thalheim's avatar Jörg Thalheim Committed by zowoq
Browse files

nixos/buildbot: allow to prepend imports

parent e2106a5d
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -15,6 +15,7 @@ let

  defaultMasterCfg = pkgs.writeText "master.cfg" ''
    from buildbot.plugins import *
    ${cfg.extraImports}
    factory = util.BuildFactory()
    c = BuildmasterConfig = dict(
     workers       = [${concatStringsSep "," cfg.workers}],
@@ -101,6 +102,13 @@ in {
        default = "c['buildbotNetUsageData'] = None";
      };

      extraImports = mkOption {
        type = types.str;
        description = lib.mdDoc "Extra python imports to prepend to master.cfg";
        default = "";
        example = "from buildbot.process.project import Project";
      };

      masterCfg = mkOption {
        type = types.path;
        description = lib.mdDoc "Optionally pass master.cfg path. Other options in this configuration will be ignored.";