[NixOS] Add bitwarden service
This commit is contained in:
parent
d8acebfe81
commit
bdb36cc8ad
@ -1,4 +1,4 @@
|
|||||||
{ config, pkgs, options, inputs, makeEnable, ... }:
|
{ config, pkgs, options, inputs, makeEnable, forEachUser, ... }:
|
||||||
makeEnable config "modules.desktop" true {
|
makeEnable config "modules.desktop" true {
|
||||||
imports = [
|
imports = [
|
||||||
./fonts.nix
|
./fonts.nix
|
||||||
@ -117,4 +117,22 @@ makeEnable config "modules.desktop" true {
|
|||||||
vscode
|
vscode
|
||||||
zoom-us
|
zoom-us
|
||||||
] else []);
|
] else []);
|
||||||
|
|
||||||
|
home-manager.users = forEachUser (if pkgs.system == "x86_64-linux" then {
|
||||||
|
systemd.user.services.bitwarden = {
|
||||||
|
Unit = {
|
||||||
|
Description = "Bitwarden";
|
||||||
|
After = [ "graphical-session-pre.target" "tray.target" ];
|
||||||
|
PartOf = [ "graphical-session.target" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
Install = { WantedBy = [ "graphical-session.target" ]; };
|
||||||
|
|
||||||
|
Service = {
|
||||||
|
ExecStart = "${pkgs.bitwarden}/bin/bitwarden";
|
||||||
|
Restart = "always";
|
||||||
|
RestartSec = 3;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
} else {});
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user