ssh module reorg
This commit is contained in:
@@ -4,7 +4,6 @@
|
||||
{
|
||||
imports = with inputs.self.homeModules; [
|
||||
rebuild
|
||||
# ssh
|
||||
git
|
||||
shell-tools
|
||||
];
|
||||
|
||||
@@ -3,6 +3,19 @@ let
|
||||
userName = "john";
|
||||
in
|
||||
{
|
||||
flake.modules.nixos.ssh = {
|
||||
services.openssh = {
|
||||
enable = true;
|
||||
# require public key authentication for better security
|
||||
settings.PasswordAuthentication = false;
|
||||
settings.KbdInteractiveAuthentication = false;
|
||||
};
|
||||
|
||||
home-manager.sharedModules = with inputs.self.homeModules; [
|
||||
ssh
|
||||
];
|
||||
};
|
||||
|
||||
flake.homeModules.ssh = { pkgs, config, lib, ... }:
|
||||
{
|
||||
options.ssh = {
|
||||
@@ -117,17 +130,4 @@ in
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
flake.modules.nixos.ssh = {
|
||||
services.openssh = {
|
||||
enable = true;
|
||||
# require public key authentication for better security
|
||||
settings.PasswordAuthentication = false;
|
||||
settings.KbdInteractiveAuthentication = false;
|
||||
};
|
||||
|
||||
home-manager.sharedModules = with inputs.self.homeModules; [
|
||||
ssh
|
||||
];
|
||||
};
|
||||
}
|
||||
|
||||
@@ -7,13 +7,13 @@ in
|
||||
flake.modules.nixos."${hostname}" = { pkgs, ... }: {
|
||||
imports = [
|
||||
inputs.self.modules.nixos.lxc
|
||||
inputs.home-manager.nixosModules.home-manager
|
||||
inputs.self.modules.nixos."${username}"
|
||||
# inputs.self.modules.nixos.step-ca
|
||||
inputs.self.modules.nixos.docker
|
||||
];
|
||||
home-manager.users."${username}" = {
|
||||
imports = with inputs.self.homeModules; [
|
||||
ssh
|
||||
];
|
||||
docker.enable = true;
|
||||
ssh.matchSets = {
|
||||
@@ -26,7 +26,6 @@ in
|
||||
flake.nixosConfigurations."${hostname}" = inputs.nixpkgs.lib.nixosSystem {
|
||||
modules = [
|
||||
inputs.self.modules.nixos."${hostname}"
|
||||
inputs.home-manager.nixosModules.home-manager
|
||||
];
|
||||
};
|
||||
}
|
||||
@@ -14,6 +14,7 @@
|
||||
flake.nixosConfigurations.lxc = inputs.nixpkgs.lib.nixosSystem {
|
||||
modules = [
|
||||
inputs.self.modules.nixos.lxc
|
||||
inputs.self.modules.nixos.ssh
|
||||
];
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user