Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 9 additions & 2 deletions hosts/gateway/configuration.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
{ suites, profiles, ... }: {
{
suites,
profiles,
secrets,
...
}:
{
imports =
with suites;
core
Expand All @@ -14,7 +20,8 @@
++ [
./disk-config.nix
./hardware-configuration.nix
];
]
++ [ secrets.hosts.gateway.configuration ];

deployment = {
vmType = "hcloud";
Expand Down
12 changes: 6 additions & 6 deletions hosts/gateway/profiles/caddy/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -100,12 +100,12 @@ in

"radarr.e10.camp" = {
host = hosts.htpc;
inherit (hosts.htpc.config.services.radarr) port;
inherit (hosts.htpc.config.services.radarr.settings.server) port;
};

"sonarr.e10.camp" = {
host = hosts.htpc;
inherit (hosts.htpc.config.services.sonarr) port;
inherit (hosts.htpc.config.services.sonarr.settings.server) port;
};

"bazarr.e10.camp" = {
Expand Down Expand Up @@ -284,10 +284,10 @@ in
port = 8123;
};

"frigate.e10.camp" = {
host = hosts.whirlwind;
port = 8971;
};
# "frigate.e10.camp" = {
# host = hosts.whirlwind;
# port = 8971;
# };

"analytics.e10.camp" = {
host = hosts.matrix;
Expand Down
5 changes: 5 additions & 0 deletions hosts/htpc/configuration.nix
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,13 @@
profiles.media-management.wizarr
profiles.services.attic-watch-store.default
profiles.sharing.nfs-client
profiles.telemetry.prometheus-bazarr-exporter
profiles.telemetry.prometheus-dcgm-exporter
profiles.telemetry.prometheus-plex-exporter.default
profiles.telemetry.prometheus-prowlarr-exporter
profiles.telemetry.prometheus-radarr-exporter
profiles.telemetry.prometheus-sabnzbd-exporter
profiles.telemetry.prometheus-sonarr-exporter
profiles.virtualisation.docker
]
++ [
Expand Down
133 changes: 0 additions & 133 deletions lib/src/generators.nix

This file was deleted.

13 changes: 0 additions & 13 deletions modules/nixos/services/radarr/default.nix

This file was deleted.

13 changes: 0 additions & 13 deletions modules/nixos/services/sonarr/default.nix

This file was deleted.

13 changes: 0 additions & 13 deletions modules/profiles/media-management/bazarr/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -396,17 +396,4 @@
enable = true;
openFirewall = true;
};

systemd.services.bazarr = {
wants = [ "sops-nix.service" ];
after = [ "sops-nix.service" ];
};

services.prometheus.exporters.exportarr-bazarr = {
enable = true;
url = "https://bazarr.e10.camp";
openFirewall = true;
apiKeyFile = config.sops.secrets.bazarr_api_key.path;
port = 9710;
};
}
2 changes: 2 additions & 0 deletions modules/profiles/media-management/plex.nix
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,6 @@
systemd.tmpfiles.rules = [
"d '/data/local/tmp/plex/transcode' 0777 ${config.services.plex.user} ${config.services.plex.group} - -"
];

systemd.services.plex.unitConfig.RequiresMountsFor = [ "/mnt/blockbuster" ];
}
44 changes: 31 additions & 13 deletions modules/profiles/media-management/prowlarr/default.nix
Original file line number Diff line number Diff line change
@@ -1,21 +1,39 @@
{ config, ... }: {
sops.secrets.prowlarr_api_key = {
sopsFile = ./secrets.json;
};
{ config, profiles, ... }: {
imports = [ profiles.secrets.prowlarr.default ] ++ [ ./postgresql.nix ];

services.prowlarr = {
enable = true;
openFirewall = true;
sops = {
templates."prowlarr/environment_file" = {
content = ''
PROWLARR__AUTH__APIKEY=${config.sops.placeholder.prowlarr_api_key}
'';
mode = "0750";
};
};

services.prometheus.exporters.exportarr-prowlarr = {
services.prowlarr = {
enable = true;
url = "https://prowlarr.e10.camp";
openFirewall = true;
apiKeyFile = config.sops.secrets.prowlarr_api_key.path;
environment = {
PROWLARR__BACKFILL = "true";
environmentFiles = [ config.sops.templates."prowlarr/environment_file".path ];
settings = {
postgres = {
host = "localhost";
port = config.services.postgresql.settings.port;
maindb = "prowlarr";
user = "prowlarr";
password = "";
};
log = {
level = "info";
dbenabled = false;
};
auth = {
method = "Forms";
required = "Enabled";
};
update = {
automatically = false;
mechanism = "external";
};
};
port = 9711;
};
}
21 changes: 21 additions & 0 deletions modules/profiles/media-management/prowlarr/postgresql.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
profiles,
...
}:
{
imports = [ profiles.databases.postgresql ];

services.postgresqlBackup.databases = [ "prowlarr" ];

services.postgresql = {
ensureDatabases = [
"prowlarr"
];
ensureUsers = [
{
name = "prowlarr";
ensureDBOwnership = true;
}
];
};
}
Loading
Loading