refactor, ssh changes
This commit is contained in:
parent
3c6fc1476a
commit
bf05141776
7 changed files with 12 additions and 15 deletions
|
|
@ -59,7 +59,6 @@
|
||||||
imports = [
|
imports = [
|
||||||
./host/roam
|
./host/roam
|
||||||
mod.shared.all
|
mod.shared.all
|
||||||
mod.server.all
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -1,12 +1,8 @@
|
||||||
{ ... }:
|
{ lib', ... }:
|
||||||
{
|
{
|
||||||
networking.hostName = "roam";
|
networking.hostName = "roam";
|
||||||
|
|
||||||
imports = [
|
imports = lib'.import-recursive ./.;
|
||||||
./hardware-configuration.nix
|
|
||||||
];
|
|
||||||
|
|
||||||
services.openssh.enable = true;
|
|
||||||
|
|
||||||
# ====== DON'T CHANGE ======
|
# ====== DON'T CHANGE ======
|
||||||
system.stateVersion = "24.11";
|
system.stateVersion = "24.11";
|
||||||
|
|
|
||||||
|
|
@ -31,5 +31,10 @@ in
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
openssh = {
|
||||||
|
enable = true;
|
||||||
|
settings.PasswordAuthentication = false;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
5
lib.nix
5
lib.nix
|
|
@ -1,5 +1,6 @@
|
||||||
{ lib, ... }:
|
{ lib, ... }:
|
||||||
rec {
|
rec {
|
||||||
|
# TODO make a version that only includes nix paths.
|
||||||
walk-dir =
|
walk-dir =
|
||||||
path:
|
path:
|
||||||
let
|
let
|
||||||
|
|
@ -15,4 +16,8 @@ rec {
|
||||||
else
|
else
|
||||||
builtins.throw "Items of type ${value} are unsupported.";
|
builtins.throw "Items of type ${value} are unsupported.";
|
||||||
}) dir;
|
}) dir;
|
||||||
|
|
||||||
|
# Takes a path `p` and returns a flattened lists of all files in that
|
||||||
|
# directory, ignoring `p/default.nix`.
|
||||||
|
import-recursive = path: lib.attrsets.collect builtins.isPath (walk-dir path // { default = { }; });
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,8 +0,0 @@
|
||||||
{ mod, ... }:
|
|
||||||
{
|
|
||||||
imports = with mod.server; [
|
|
||||||
services
|
|
||||||
networking
|
|
||||||
security
|
|
||||||
];
|
|
||||||
}
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue