tsuki: add notification to immich-backup

This commit is contained in:
notohh 2025-02-21 22:32:23 -05:00
parent e6be419ddd
commit a1c226c8d5
Signed by: notohh
GPG key ID: BD47506D475EE86D

View file

@ -7,8 +7,13 @@
services.immich-backup = let
homeDir = "/home/notoh";
in {
script = ''
${lib.getExe pkgs.immich-cli} upload --album-name "desktop screenshots" --recursive ${homeDir}/Pictures/screenshots
script = with pkgs; ''
echo $DISPLAY
export DISPLAY=:0.0
echo $DISPLAY
export DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
${lib.getExe immich-cli} upload --album-name "desktop screenshots" --recursive ${homeDir}/Pictures/screenshots
${lib.getExe libnotify} --app-name "immich-backup" --urgency=low --icon=dialog-information "immich backup completed"
'';
serviceConfig = {
Type = "oneshot";