mirror of
https://github.com/Stunkymonkey/nixos.git
synced 2025-05-24 09:54:40 +02:00
service/exportarr: fix apikey
This commit is contained in:
parent
724ca9dc1a
commit
e4d8129873
7 changed files with 97 additions and 13 deletions
|
@ -8,6 +8,13 @@ in
|
|||
{
|
||||
options.my.services.radarr = with lib; {
|
||||
enable = mkEnableOption "Sonarr for films management";
|
||||
|
||||
apiKeyFile = lib.mkOption {
|
||||
type = lib.types.path;
|
||||
description = lib.mdDoc ''
|
||||
File containing the api-key.
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
|
@ -29,8 +36,21 @@ in
|
|||
my.services.exportarr.radarr = {
|
||||
port = port + 1;
|
||||
url = "http://127.0.0.1:${toString port}";
|
||||
apiKeyFile = cfg.apiKeyFile;
|
||||
};
|
||||
|
||||
services.prometheus.scrapeConfigs = [
|
||||
{
|
||||
job_name = "radarr";
|
||||
static_configs = [{
|
||||
targets = [ "127.0.0.1:${toString port + 1}" ];
|
||||
labels = {
|
||||
instance = config.networking.hostName;
|
||||
};
|
||||
}];
|
||||
}
|
||||
];
|
||||
|
||||
webapps.apps.radarr = {
|
||||
dashboard = {
|
||||
name = "Movies";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue