1
0
Fork 0
mirror of https://git.gay/xqtc/nixos-config synced 2025-04-29 02:47:30 +02:00

seraphim sync service

This commit is contained in:
xqtc 2025-03-25 21:08:58 +01:00
parent 45037361f9
commit 108a6d7acf
Signed by: xqtc
GPG key ID: 2C064D095926D9D1
3 changed files with 29 additions and 1 deletions
home/modules
hosts/x86_64-linux/seraphim

View file

@ -215,7 +215,7 @@
background = [
{
# path = "~/.config/hypr/bg.png";
path = "screenshot";
path = "screenshot";
blur_passes = 3;
blur_size = 8;
# color = "rgb(0e1419)";

View file

@ -14,6 +14,7 @@
../../gc.nix
../../../common/comin.nix
./jellyfin.nix
./sync.nix
./monitoring.nix
./caddy.nix
];

View file

@ -0,0 +1,27 @@
{
lib,
inputs,
pkgs,
config,
...
}: {
systemd.timers."sync-media" = {
wantedBy = ["timers.target"];
timerConfig = {
OnCalendar = "daily";
Persisten = true;
};
};
systemd.services."sync-media" = {
script = ''
${pkgs.coreutils}/bin/echo "Syncing shows"
${pkgs.rsync}/bin/rsync -a --ignore-existing --info=progress1 /home/crime/sonarr/tvseries/ xqtc@88.99.90.90:~/jellyfin/shows/
${pkgs.coreutils}/bin/echo "Syncing movies"
${pkgs.rsync}/bin/rsync -a --ignore-existing --info=progress1 /home/crime/radarr/movies/ xqtc@88.99.90.90:~/jellyfin/movies/
'';
serviceConfig = {
Type = "oneshot";
User = "xqtc";
};
};
}