diff options
-rw-r--r-- | bragi.nix | 17 |
1 files changed, 10 insertions, 7 deletions
@@ -243,12 +243,15 @@ in { | |||
243 | home = "/var/lib/thermoprint"; | 243 | home = "/var/lib/thermoprint"; |
244 | }; | 244 | }; |
245 | 245 | ||
246 | systemd.services."thermoprint" = { | 246 | let |
247 | serviceConfig = { | 247 | user = user.extraUsers."thermoprint"; |
248 | Type = "simple"; | 248 | in |
249 | ExecStart = ''${thermoprint-servant}/bin/thermoprint --database /var/thermoprint/database.sqlite /dev/usb/lp0''; | 249 | systemd.services."thermoprint" = { |
250 | User = "thermoprint"; | 250 | serviceConfig = { |
251 | Group = "lp"; | 251 | Type = "simple"; |
252 | ExecStart = ''${thermoprint-servant}/bin/thermoprint --database ${user.home}/database.sqlite /dev/usb/lp0''; | ||
253 | User = user.name; | ||
254 | Group = user.group; | ||
255 | }; | ||
252 | }; | 256 | }; |
253 | }; | ||
254 | } | 257 | } |