feat: add Bazarr service module with configuration options

This commit is contained in:
Giulio De Pasquale (aider) 2025-04-26 16:51:24 +01:00
parent 35035111e7
commit a44533a0e0
2 changed files with 39 additions and 0 deletions

View File

@ -0,0 +1,38 @@
{ config, lib, pkgs, ... }:
let
inherit (lib) mkIf;
cfg = config.pepe.services.bazarr;
in
{
options.pepe.services.bazarr = with lib; {
enable = mkEnableOption "Enable bazarr";
package = mkPackageOption pkgs "bazarr" { };
domain = mkOption {
type = types.str;
default = null;
};
};
config = mkIf cfg.enable {
services.bazarr = {
enable = true;
package = cfg.package;
group = "media";
};
architect.vhost.${cfg.domain} = with config.architect.networks; {
dnsInterfaces = [ "tailscale" ];
locations."/" = {
port = 6767;
allowLan = true;
allow = [
tailscale.net
];
};
};
pepe.core.media.groupMembers = mkIf config.pepe.core.media.enable [ "bazarr" ];
};
}

View File

@ -1,5 +1,6 @@
{ ... }: {
imports = [
./bazarr
./gitea
./immich
./prowlarr