Switched from home-manger -> nixos systemd target

I'm currently trying to standardize on this due to runtime issue with
the home-manager syntax.
This commit is contained in:
James Patrick 2022-07-16 18:46:36 -04:00
parent 5fc72bd6d4
commit 4e6b969cc7
1 changed files with 15 additions and 17 deletions

View File

@ -13,24 +13,22 @@ in with lib; {
config = mkIf cfg.enable {
home-manager.users.james = {
home.packages = with pkgs; [ nextcloud-client ];
};
systemd.user.services = {
nextcloud = {
Unit = {
Description = "Nextcloud - A slightly more GNU friendly dropbox";
BindsTo = [ "graphical-session.target" ];
Wants = [ "graphical-session-pre.target" ];
After = [ "graphical-session-pre.target" ];
};
Service = {
Type = "simple";
ExecStart = "${pkgs.nextcloud-client}/bin/nextcloud --background";
Environment = "QT_XCB_GL_INTEGRATION=none";
Restart = "on-failure";
RestartSec = 1;
TimeoutStopSec = 10;
};
systemd.user.services = {
nextcloud = {
enable = true;
description =
"Nextcloud Client - A slightly more GNU friendly dropbox ";
wantedBy = [ "graphical-session.target" ];
partOf = [ "graphical-session.target" ];
serviceConfig = {
Type = "simple";
ExecStart = "${pkgs.nextcloud-client}/bin/nextcloud --background";
Environment = "QT_XCB_GL_INTEGRATION=none";
Restart = "on-failure";
RestartSec = 1;
TimeoutStopSec = 10;
};
};
};