feat: flake interface definition
This commit is contained in:
9
hosts/default.nix
Normal file
9
hosts/default.nix
Normal file
@ -0,0 +1,9 @@
|
||||
inputs @ {nixpkgs, ...}:
|
||||
let
|
||||
inherit (nixpkgs) lib;
|
||||
isDir = _name: type: type == "directory";
|
||||
directoriesAsModules = dir: (builtins.mapAttrs
|
||||
(name: _value: dir + "/${name}")
|
||||
(lib.filterAttrs isDir (builtins.readDir dir))
|
||||
);
|
||||
in directoriesAsModules ./.
|
8
hosts/git.example.tld/default.nix
Normal file
8
hosts/git.example.tld/default.nix
Normal file
@ -0,0 +1,8 @@
|
||||
inputs @ {config, ...}:
|
||||
let
|
||||
allusers = (import ../../users) inputs;
|
||||
{
|
||||
users.users = {
|
||||
inherit (allUsers) alice bob;
|
||||
}
|
||||
}
|
8
hosts/web.example.org/default.nix
Normal file
8
hosts/web.example.org/default.nix
Normal file
@ -0,0 +1,8 @@
|
||||
inputs @ {config, ...}:
|
||||
let
|
||||
allusers = (import ../../users) inputs;
|
||||
{
|
||||
users.users = {
|
||||
inherit (allUsers) alice bob mallory root;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user