os/modules/server/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

34 lines
660 B
Nix
Raw Normal View History

2023-03-07 15:48:46 +00:00
{
lib,
config,
pkgs,
...
}:
with lib; let
2022-08-21 22:07:09 +00:00
psCfg = config.pub-solar;
cfg = config.pub-solar.server;
2023-03-07 15:48:46 +00:00
in {
2022-08-21 22:07:09 +00:00
options.pub-solar.server = {
enable = mkEnableOption "Enable server options like sshd";
};
config = mkIf cfg.enable {
pub-solar.core.lite = true;
services = {
lldpd.enable = true;
openssh = {
enable = true;
openFirewall = true;
settings = {
PermitRootLogin = lib.mkForce "prohibit-password";
PasswordAuthentication = true;
};
};
2022-08-21 22:07:09 +00:00
};
2023-03-07 15:48:46 +00:00
networking.networkmanager.enable = lib.mkForce false;
pub-solar.nextcloud.enable = lib.mkForce false;
2022-08-21 22:07:09 +00:00
};
}