Merge pull request #44 from wi11-holdsworth/enhancement/37
enhancement/37
This commit is contained in:
commit
ca3a986b4d
6 changed files with 32 additions and 6 deletions
|
|
@ -25,7 +25,19 @@
|
|||
|
||||
networking.hostName = "${hostName}";
|
||||
|
||||
services.openssh.enable = true;
|
||||
# hardened openssh
|
||||
services.openssh = {
|
||||
passwordAuthentication = false;
|
||||
allowSFTP = false;
|
||||
challengeResponseAuthentication = false;
|
||||
extraConfig = ''
|
||||
AllowTcpForwarding yes
|
||||
X11Forwarding no
|
||||
AllowAgentForwarding no
|
||||
AllowStreamLocalForwarding no
|
||||
AuthenticationMethods publickey
|
||||
'';
|
||||
};
|
||||
|
||||
system.stateVersion = "24.11";
|
||||
|
||||
|
|
|
|||
|
|
@ -13,8 +13,7 @@
|
|||
"localisation"
|
||||
"network"
|
||||
"nh"
|
||||
"nix-settings"
|
||||
"nixpkgs"
|
||||
"nix"
|
||||
"nixvim"
|
||||
"syncthing"
|
||||
"systemd-boot"
|
||||
|
|
|
|||
|
|
@ -6,5 +6,6 @@
|
|||
networking = {
|
||||
hostName = "${hostName}";
|
||||
networkmanager.enable = true;
|
||||
firewall.enable = true;
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,4 +1,14 @@
|
|||
{
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
{
|
||||
# rip out default packages
|
||||
environment.defaultPackages = lib.mkForce [ ];
|
||||
|
||||
# allow packages with non-free licenses
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
||||
nix = {
|
||||
gc = {
|
||||
automatic = true;
|
||||
|
|
@ -11,6 +21,7 @@
|
|||
persistent = true;
|
||||
};
|
||||
settings = {
|
||||
allowed-users = [ "@wheel" ];
|
||||
experimental-features = [
|
||||
"nix-command"
|
||||
"flakes"
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
{
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
}
|
||||
6
modules/nixos/features/sudo.nix
Normal file
6
modules/nixos/features/sudo.nix
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
...
|
||||
}:
|
||||
{
|
||||
security.sudo.execWheelOnly = true;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue