diff options
author | nin <nineinchnade@gmail.com> | 2017-07-13 23:53:54 +0200 |
---|---|---|
committer | nin <nineinchnade@gmail.com> | 2017-07-13 23:53:54 +0200 |
commit | 01fc0e14ef3b6a8af8bb60f84ebb6b5474bab410 (patch) | |
tree | ae0773971f6061406f7ef0bf8d93bdba34e9a8ef /nin | |
parent | c4627764062a42f8d952ff90557c1e0d8735485f (diff) |
move source config from module system to 1systems/*/source.nix
Diffstat (limited to 'nin')
-rw-r--r-- | nin/1systems/hiawatha/config.nix (renamed from nin/1systems/hiawatha.nix) | 17 | ||||
-rw-r--r-- | nin/1systems/hiawatha/source.nix | 4 | ||||
-rw-r--r-- | nin/1systems/onondaga/config.nix (renamed from nin/1systems/onondaga.nix) | 8 | ||||
-rw-r--r-- | nin/1systems/onondaga/source.nix | 4 | ||||
-rw-r--r-- | nin/2configs/default.nix | 9 | ||||
-rw-r--r-- | nin/2configs/nixpkgs.nix | 8 | ||||
-rw-r--r-- | nin/source.nix | 19 |
7 files changed, 42 insertions, 27 deletions
diff --git a/nin/1systems/hiawatha.nix b/nin/1systems/hiawatha/config.nix index 12f2718bc..0e48b41c2 100644 --- a/nin/1systems/hiawatha.nix +++ b/nin/1systems/hiawatha/config.nix @@ -8,13 +8,13 @@ with lib; { imports = [ - ../. + <stockholm/nin> <nixpkgs/nixos/modules/installer/scan/not-detected.nix> - ../2configs/copyq.nix - ../2configs/games.nix - ../2configs/git.nix - ../2configs/retiolum.nix - ../2configs/termite.nix + #../2configs/copyq.nix + <stockholm/nin/2configs/games.nix> + <stockholm/nin/2configs/git.nix> + <stockholm/nin/2configs/retiolum.nix> + <stockholm/nin/2configs/termite.nix> ]; krebs.build.host = config.krebs.hosts.hiawatha; @@ -33,6 +33,11 @@ with lib; fsType = "tmpfs"; }; + fileSystems."/home" = + { device = "/dev/fam/home"; + }; + + fileSystems."/boot" = { device = "/dev/disk/by-uuid/2f319b08-2560-401d-b53c-2abd28f1a010"; fsType = "ext2"; diff --git a/nin/1systems/hiawatha/source.nix b/nin/1systems/hiawatha/source.nix new file mode 100644 index 000000000..a4b366b9c --- /dev/null +++ b/nin/1systems/hiawatha/source.nix @@ -0,0 +1,4 @@ +import <stockholm/nin/source.nix> { + name = "hiawatha"; + secure = true; +} diff --git a/nin/1systems/onondaga.nix b/nin/1systems/onondaga/config.nix index 576847032..242d67c26 100644 --- a/nin/1systems/onondaga.nix +++ b/nin/1systems/onondaga/config.nix @@ -6,11 +6,11 @@ { imports = [ - ../. + <stockholm/nin> <nixpkgs/nixos/modules/profiles/qemu-guest.nix> - ../2configs/retiolum.nix - ../2configs/weechat.nix - ../2configs/git.nix + <stockholm/nin/2configs/retiolum.nix> + <stockholm/nin/2configs/weechat.nix> + <stockholm/nin/2configs/git.nix> ]; krebs.build.host = config.krebs.hosts.onondaga; diff --git a/nin/1systems/onondaga/source.nix b/nin/1systems/onondaga/source.nix new file mode 100644 index 000000000..60d020222 --- /dev/null +++ b/nin/1systems/onondaga/source.nix @@ -0,0 +1,4 @@ +import <stockholm/nin/source.nix> { + name = "onondaga"; + secure = true; +} diff --git a/nin/2configs/default.nix b/nin/2configs/default.nix index cb02521ce..212fd368e 100644 --- a/nin/2configs/default.nix +++ b/nin/2configs/default.nix @@ -3,7 +3,6 @@ with import <stockholm/lib>; { imports = [ - ../2configs/nixpkgs.nix ../2configs/vim.nix { users.extraUsers = @@ -62,14 +61,6 @@ with import <stockholm/lib>; search-domain = "r"; build = { user = config.krebs.users.nin; - source = let inherit (config.krebs.build) host; in { - nixos-config.symlink = "stockholm/nin/1systems/${host.name}.nix"; - secrets.file = - if getEnv "dummy_secrets" == "true" - then toString <stockholm/nin/6tests/dummysecrets> - else "/home/nin/secrets/${host.name}"; - stockholm.file = getEnv "PWD"; - }; }; }; diff --git a/nin/2configs/nixpkgs.nix b/nin/2configs/nixpkgs.nix deleted file mode 100644 index c46331b0d..000000000 --- a/nin/2configs/nixpkgs.nix +++ /dev/null @@ -1,8 +0,0 @@ -{ ... }: - -{ - krebs.build.source.nixpkgs.git = { - url = https://github.com/nixos/nixpkgs; - ref = "01c3847"; - }; -} diff --git a/nin/source.nix b/nin/source.nix new file mode 100644 index 000000000..1eb9185ab --- /dev/null +++ b/nin/source.nix @@ -0,0 +1,19 @@ +with import <stockholm/lib>; +host@{ name, secure ? false }: let + builder = if getEnv "dummy_secrets" == "true" + then "buildbot" + else "nin"; + _file = <stockholm> + "/nin/1systems/${name}/source.nix"; +in + evalSource (toString _file) { + nixos-config.symlink = "stockholm/nin/1systems/${name}/config.nix"; + secrets.file = getAttr builder { + buildbot = toString <stockholm/nin/2configs/tests/dummy-secrets>; + nin = "/home/nin/secrets/${name}"; + }; + stockholm.file = toString <stockholm>; + nixpkgs.git = { + url = https://github.com/nixos/nixpkgs; + ref = "01c3847"; + }; + } |