nixos-config/modules/nixos/agenix.nix

20 lines
527 B
Nix
Raw Normal View History

# A module that automates setting up agenix for your system.
{ inputs, lib, options, config, ... }:
2021-11-25 13:45:48 +00:00
let cfg = config.modules.agenix;
in {
2021-11-25 13:45:48 +00:00
options.modules.agenix.enable =
lib.mkEnableOption "Automate agenix-related config on your system";
imports = [ inputs.agenix.nixosModules.age ];
config = lib.mkIf cfg.enable {
# Enable all relevant services.
programs.gnupg.agent = {
enable = true;
enableSSHSupport = true;
};
services.sshd.enable = true;
services.openssh.enable = true;
};
}