Start xiccd as a systemd user service

I’m trying to start xiccd as a user service, but starting the service always fails with the message:

systemctl status xiccd.service                                                                                        ~
● xiccd.service
   Loaded: bad-setting (Reason: Unit xiccd.service has a bad unit file setting.)
   Active: inactive (dead)

Nov 11 19:41:14 nefastis systemd[1]: xiccd.service: Service has no ExecStart=, ExecStop=, or SuccessAction=. Refusing.

This is in my configuration.nix:

 systemd.user.services.xiccd = {
   description = "Xiccd Screen Color Profiler";
   serviceConfig = {
     ExecStart = "${pkgs.xiccd}/bin/xiccd";
     ExecStop = "pkill xiccd";
     Restart = "always";
   };
   wantedBy = [ "dbus.service" ];
   after = [ "dbus.service" ];
   partOf = [ "dbus.service" ];
 };

 systemd.services.xiccd.enable = true;


You’re defining xiccd as a user service (systemd.user.services), but activating it as a system service (systemd.services).

I suspect that you want the last line to be:

systemd.user.services.xiccd.enable = true;
1 Like

Shouldn’t it be enabled by default? I don’t think the enable line is even necessary.

Anyway, @paperdigits, you’re seeing the error with systemctl status xiccd.service because, as @necopinus says, you’re accidentally creating a system service by writing the enable line on the system option, not the user option, which creates a system service with none of the required fields filled out. To see the user service status, you need to use systemctl --user status xiccd.service

2 Likes