icloud backup with kdrive

This commit is contained in:
2026-06-18 19:47:41 +02:00
parent 97beca4f88
commit a619a10851
2 changed files with 20 additions and 6 deletions
+13
View File
@@ -53,6 +53,19 @@
monitor = [
", highres@highrr, auto, 0.75"
];
exec-once = [
"if [ -e \"/home/tomasr/icloudSync.sh\" ]; then /home/tomasr/icloudSync.sh; else notify-send \"icloudSync.sh doesn't exist\" \"See ~/nixos/modules/applications/hyprland.nix for more information\"; fi"
# my icloud account uses an email that I don't want to make public. So the script isnt pushed to github. The script looks like:
/*
#!/etc/profiles/per-user/tomasr/bin/zsh
if ! icloudpd --auth-only --username tomas.rivera_2009@icloud.com --dry-run; then
notify-send "icloudpd is not logged in" "Please run icloudpd icloudpd --username my@email.address --password my_password --auth-only"
exit 1
fi
icloudpd --directory ~/hdd/kdrive/Photo/IPhone/icloudpd-backup --username tomas.rivera_2009@icloud.com --watch-with-interval 3600 --no-progress-bar
*/
];
};
};
flake.homeModules.hyprland = {pkgs-unstable, ...}: let
+7 -6
View File
@@ -11,11 +11,12 @@
enable = true;
};
};
flake.nixosModules.kdrive-desktop = {pkgs, ...}: {
environment.systemPackages = [
pkgs.rclone
self.packages.${pkgs.system}.custom-checkKdrive
self.packages.${pkgs.system}.custom-synckdrive-desktop
flake.nixosModules.kdrive-desktop = {pkgs-unstable, ...}: {
environment.systemPackages = with pkgs-unstable; [
rclone
icloudpd
self.packages.${pkgs-unstable.system}.custom-checkKdrive
self.packages.${pkgs-unstable.system}.custom-synckdrive-desktop
];
# removes rclone error
programs.fuse = {
@@ -24,7 +25,7 @@
};
systemd.user.services.kdrive-sync = {
serviceConfig = {
ExecStart = "${self.packages.${pkgs.system}.custom-synckdrive-desktop}/bin/custom-synckdrive";
ExecStart = "${self.packages.${pkgs-unstable.system}.custom-synckdrive-desktop}/bin/custom-synckdrive";
Nice = 19; # lowest CPU scheduling priority
IOSchedulingClass = "idle";