nix-configs/nixos-modules/docker-sonarr.nix

40 lines
926 B
Nix
Raw Normal View History

2024-10-02 21:23:25 -04:00
{ pkgs, ... }:
2024-10-01 17:42:47 -04:00
{
virtualisation = {
containers.enable = true;
podman.enable = true;
oci-containers.containers = {
sonarr = {
2024-10-02 21:23:25 -04:00
image = "my-sonarr:latest";
imageFile = pkgs.dockerTools.buildLayeredImage {
name = "my-sonarr";
tag = "latest";
contents = [ pkgs.busybox ];
config = {
User = "911:911";
Cmd = [
"${pkgs.sonarr}/bin/NzbDrone"
"-nobrowser"
"-data=/config"
];
};
};
2024-10-01 17:42:47 -04:00
volumes = [
"sonarr-config:/config"
"/video-data:/data"
];
environment.TZ = "America/New_York";
2024-10-02 21:23:25 -04:00
labels = {
swag = "enable";
swag_url = "sonarr.icanttype.org";
swag_port = "8989";
};
2024-10-01 17:42:47 -04:00
extraOptions = [
"--pull=newer"
"--network=www"
];
};
};
};
}