diff options
Diffstat (limited to 'modules/containers/pinchflat')
-rw-r--r-- | modules/containers/pinchflat/default.nix | 20 |
1 files changed, 8 insertions, 12 deletions
diff --git a/modules/containers/pinchflat/default.nix b/modules/containers/pinchflat/default.nix index 8ee831f..996476d 100644 --- a/modules/containers/pinchflat/default.nix +++ b/modules/containers/pinchflat/default.nix @@ -1,23 +1,19 @@ -{ ... }: +{ lib, ... }: let - directories = [ - "/opt/pinchflat" - ]; + inherit (lib.lists) singleton; + directory = "/opt/pinchflat"; in { - systemd.tmpfiles.rules = map (x: "d ${x} 0755 share share - -") directories; + systemd.tmpfiles.rules = builtins.map (x: "d ${x} 0755 share share - -") (singleton directory); + virtualisation.oci-containers.containers.pinchflat = { image = "keglin/pinchflat:latest"; autoStart = true; - ports = [ - "8945:8945" - ]; + ports = singleton "8945:8945"; volumes = [ - "/opt/pinchflat:/config" + "${directory}:/config" "/tank/media/yt:/downloads" ]; - environment = { - TZ = "America/Detroit"; - }; + environment.TZ = "America/Detroit"; }; } |