aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaroline Larimore <caroline@larimo.re>2025-05-16 16:58:51 -0700
committerCaroline Larimore <caroline@larimo.re>2025-05-16 16:58:51 -0700
commit5264ba4eedd88ab68bd67c482bbe4398ad9385b5 (patch)
tree78d1c720ee40d61e345307b922cd66ffbfa3f3de
parent3c070bcf4fdd913644bd95aad2dc9b43cbd892eb (diff)
copenhagen: allow ssh on port 22
-rw-r--r--modules/nixos/services/ssh/default.nix10
-rw-r--r--systems/x86_64-linux/copenhagen/default.nix2
2 files changed, 6 insertions, 6 deletions
diff --git a/modules/nixos/services/ssh/default.nix b/modules/nixos/services/ssh/default.nix
index e09a7e3..283b4f3 100644
--- a/modules/nixos/services/ssh/default.nix
+++ b/modules/nixos/services/ssh/default.nix
@@ -7,17 +7,17 @@ in {
options.${namespace}.services.ssh = with types; {
enable = mkEnableOption "ssh server";
- port = mkOption {
- type = types.port;
- default = 22;
- description = "ssh server port";
+ ports = mkOption {
+ type = listOf port;
+ default = [ 22 ];
+ description = "ssh server ports";
};
};
config = mkIf cfg.enable {
services.openssh = {
enable = true;
- ports = [ cfg.port ];
+ ports = cfg.ports;
settings = {
PermitRootLogin = "no";
diff --git a/systems/x86_64-linux/copenhagen/default.nix b/systems/x86_64-linux/copenhagen/default.nix
index 8fcda09..7b342a1 100644
--- a/systems/x86_64-linux/copenhagen/default.nix
+++ b/systems/x86_64-linux/copenhagen/default.nix
@@ -20,7 +20,7 @@ with lib; with lib.${namespace}; {
services = {
ssh = {
enable = true;
- port = 42069;
+ ports = [ 22 42069 ];
};
web = {