2022-01-22 21:14:30 +00:00
|
|
|
{ lib, config, pkgs, ... }:
|
|
|
|
with lib;
|
|
|
|
let
|
|
|
|
psCfg = config.pub-solar;
|
|
|
|
cfg = config.pub-solar.server;
|
|
|
|
in
|
|
|
|
{
|
|
|
|
options.pub-solar.server = {
|
|
|
|
enable = mkEnableOption "Enable server options like sshd";
|
|
|
|
};
|
|
|
|
|
|
|
|
config = mkIf cfg.enable {
|
|
|
|
services.openssh = {
|
|
|
|
enable = true;
|
2022-05-06 16:38:55 +00:00
|
|
|
permitRootLogin = lib.mkForce "prohibit-password";
|
2022-01-22 21:14:30 +00:00
|
|
|
passwordAuthentication = true;
|
|
|
|
openFirewall = true;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|