Compare commits
2 Commits
edc1e6149a
...
1c582a48a4
| Author | SHA1 | Date | |
|---|---|---|---|
|
1c582a48a4
|
|||
|
cf8d0e72fe
|
@@ -1,14 +1,5 @@
|
|||||||
{ pkgs, lib, inputs, ... }:
|
{ pkgs, lib, ... }:
|
||||||
let
|
|
||||||
keys = import ../../users/matej/keys.nix;
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
imports = [
|
|
||||||
inputs.self.nixosModules.openssh
|
|
||||||
];
|
|
||||||
|
|
||||||
openssh.enable = true;
|
|
||||||
|
|
||||||
image.modules.iso-installer = {
|
image.modules.iso-installer = {
|
||||||
isoImage.squashfsCompression = "zstd -Xcompression-level 6";
|
isoImage.squashfsCompression = "zstd -Xcompression-level 6";
|
||||||
};
|
};
|
||||||
@@ -19,6 +10,17 @@ in
|
|||||||
};
|
};
|
||||||
boot.loader.grub.device = lib.mkDefault "/dev/sda";
|
boot.loader.grub.device = lib.mkDefault "/dev/sda";
|
||||||
|
|
||||||
|
services.openssh = {
|
||||||
|
enable = true;
|
||||||
|
ports = [ 22 ];
|
||||||
|
settings = {
|
||||||
|
PasswordAuthentication = false;
|
||||||
|
AllowUsers = null;
|
||||||
|
PermitRootLogin = "no";
|
||||||
|
StreamLocalBindUnlink = "yes";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
networking.firewall.allowedTCPPorts = [ 22 ];
|
networking.firewall.allowedTCPPorts = [ 22 ];
|
||||||
|
|
||||||
users = {
|
users = {
|
||||||
@@ -36,9 +38,14 @@ in
|
|||||||
"wheel"
|
"wheel"
|
||||||
"users"
|
"users"
|
||||||
];
|
];
|
||||||
openssh.authorizedKeys.keys = keys.sshAuthorizedKeys;
|
openssh.authorizedKeys.keys = [
|
||||||
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICQGLdINKzs+sEy62Pefng0bcedgU396+OryFgeH99/c janezicmatej"
|
||||||
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# boot.extraModulePackages = [ pkgs.linuxPackages.r8125 ];
|
||||||
|
# boot.blacklistedKernelModules = [ "r8169" ];
|
||||||
|
|
||||||
system.stateVersion = "25.05";
|
system.stateVersion = "25.05";
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user