2016-10-18 21:14:18 +00:00
|
|
|
{ config, lib, pkgs, ... }:
|
|
|
|
|
|
|
|
with lib;
|
|
|
|
|
|
|
|
let
|
|
|
|
|
|
|
|
cfg = config.system;
|
|
|
|
|
|
|
|
in {
|
|
|
|
options = {
|
|
|
|
|
|
|
|
system.build = mkOption {
|
|
|
|
internal = true;
|
2016-10-19 18:03:17 +00:00
|
|
|
type = types.attrsOf types.package;
|
2016-10-18 21:14:18 +00:00
|
|
|
default = {};
|
|
|
|
description = ''
|
|
|
|
Attribute set of derivation used to setup the system.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2016-10-19 18:03:17 +00:00
|
|
|
system.path = mkOption {
|
2016-10-18 21:14:18 +00:00
|
|
|
internal = true;
|
2016-10-19 18:03:17 +00:00
|
|
|
type = types.package;
|
|
|
|
description = ''
|
|
|
|
The packages you want in the system environment.
|
|
|
|
'';
|
2016-10-18 21:14:18 +00:00
|
|
|
};
|
|
|
|
|
2016-10-19 18:03:17 +00:00
|
|
|
# Used by <nixos/modules/system/etc/etc.nix>
|
|
|
|
system.activationScripts = mkOption { internal = true; };
|
|
|
|
|
2016-10-18 21:14:18 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
config = {
|
|
|
|
|
|
|
|
system.build.toplevel = pkgs.buildEnv {
|
|
|
|
name = "nixdarwin-system";
|
2016-10-19 18:03:17 +00:00
|
|
|
paths = [ cfg.path cfg.build.etc ];
|
2016-10-18 21:14:18 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
};
|
|
|
|
}
|