diff --git a/modules/nixos/jellyfin.nix b/modules/nixos/jellyfin.nix index 235285e..b9ca0d0 100644 --- a/modules/nixos/jellyfin.nix +++ b/modules/nixos/jellyfin.nix @@ -1,24 +1,14 @@ -{ pkgs, ... }: { services.jellyfin.enable = true; # port = 8096 ## Grab EPG data daily - systemd = { - services = { + virtualisation.oci-containers = { + containers = { epg = { - script = "${pkgs.nodejs}/bin/npm run --prefix /mnt/media/TV/epg/ grab --- --channels=/mnt/media/TV/custom.channels.xml"; - path = [ - pkgs.bash - pkgs.nodejs - ]; - serviceConfig = { - Type = "oneshot"; - User = "root"; - }; - ## Creates a timer - startAt = "daily"; + image = "ghcr.io/iptv-org/epg:master"; + ports = [ "3001:3000" ]; + volumes = [ "/mnt/media/TV/custom.channels.xml:/epg/public/channels.xml" ]; }; }; - timers.epg.timerConfig.Persistent = true; }; }