initial commit
This commit is contained in:
21
modules/endlessh.nix
Normal file
21
modules/endlessh.nix
Normal file
@@ -0,0 +1,21 @@
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib; let
|
||||
cfg = config.modules.endlessh;
|
||||
in {
|
||||
options.modules.endlessh = {
|
||||
enable = mkEnableOption "Enables endlessh.";
|
||||
port = mkOption {
|
||||
type = types.port;
|
||||
default = 2222;
|
||||
example = 22;
|
||||
};
|
||||
};
|
||||
config.services.endlessh-go = mkIf cfg.enable {
|
||||
inherit (cfg) enable port;
|
||||
openFirewall = true;
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user