1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-11-05 10:49:44 +01:00
home-manager/modules/services/keepassx.nix
2020-02-02 01:07:28 +01:00

27 lines
625 B
Nix

{ config, lib, pkgs, ... }:
with lib;
{
meta.maintainers = [ maintainers.rycee ];
options = {
services.keepassx = {
enable = mkEnableOption "the KeePassX password manager";
};
};
config = mkIf config.services.keepassx.enable {
systemd.user.services.keepassx = {
Unit = {
Description = "KeePassX password manager";
After = [ "graphical-session-pre.target" ];
PartOf = [ "graphical-session.target" ];
};
Install = { WantedBy = [ "graphical-session.target" ]; };
Service = { ExecStart = "${pkgs.keepassx}/bin/keepassx -min -lock"; };
};
};
}