add generators and clean up directories

This commit is contained in:
Noah Masur
2025-03-14 00:13:56 +00:00
parent bdf163a50a
commit a3ad019f4b
11 changed files with 145 additions and 115 deletions

View File

@ -0,0 +1,27 @@
# SSHD settings for AWS machines
{
config,
lib,
...
}:
let
cfg = config.nmasur.presets.services.openssh-aws;
in
{
options.nmasur.presets.services.openssh-aws = {
enable = lib.mkEnableOption "OpenSSH on AWS VMs";
};
config = lib.mkIf cfg.enable {
services.openssh = {
settings = {
# AWS settings require this
PermitRootLogin = lib.mkForce "prohibit-password";
};
};
};
}

View File

@ -52,19 +52,6 @@ in
pkgs.curl
];
# Include home-manager config in NixOS
home-manager = {
sharedModules = [ ../../../../home-manager ];
# Use the system-level nixpkgs instead of Home Manager's
useGlobalPkgs = lib.mkDefault true;
# Install packages to /etc/profiles instead of ~/.nix-profile, useful when
# using multiple profiles for one user
useUserPackages = lib.mkDefault true;
};
# Extending time for home-manager build for things like nix-index cache
systemd.services."home-manager-${username}" = {
serviceConfig.TimeoutStartSec = lib.mkForce "45m";