tsuki/navidrome: init

This commit is contained in:
Oystein Kristoffer Tveit 2023-07-28 21:50:38 +02:00
parent c2026eefeb
commit b5874e2bcd
Signed by: oysteikt
GPG Key ID: 9F2F7D8250F35146
3 changed files with 24 additions and 1 deletions

View File

@ -15,7 +15,7 @@
./services/kanidm.nix
./services/matrix
./services/minecraft
./services/nextcloud.nix
./services/navidrome.nix
./services/nginx
./services/osuchan.nix
./services/pgadmin.nix

View File

@ -0,0 +1,20 @@
{ config, pkgs, ... }: let
cfg = config.services.navidrome;
in {
services.navidrome = {
enable = true;
settings = {
Address = "127.0.0.1";
Port = 4533;
MusicFolder = "/data2/media/music";
Prometheus.Enabled = true;
};
};
local.socketActivation.navidrome = {
enable = true;
originalSocketAddress = "${cfg.settings.Address}:${toString cfg.settings.Port}";
newSocketAddress = "/run/navidrome.sock";
privateNamespace = false;
};
}

View File

@ -39,6 +39,7 @@
upstreams = let
inherit (secrets) ips ports;
srv = config.services;
sa = config.local.socketActivation;
in {
"atuin".servers."localhost:${s srv.atuin.port}" = { };
"dynmap".servers."localhost:${s ports.minecraft.dynmap}" = { };
@ -51,6 +52,7 @@
"invidious".servers."localhost:${s config.services.invidious.port}" = { };
"jupyter".servers."unix:/run/jupyter/jupyter.sock" = { };
"kanidm".servers."localhost:8300" = { };
"navidrome".servers."unix:${sa.navidrome.newSocketAddress}" = { };
"osuchan".servers."localhost:${s ports.osuchan}" = { };
"pgadmin".servers."unix:${srv.uwsgi.instance.vassals.pgadmin.socket}" = { };
"plex".servers."localhost:${s ports.plex}" = { };
@ -157,6 +159,7 @@
(proxy ["map"] "http://dynmap" {})
(proxy ["osu"] "http://osuchan" {})
(proxy ["plex"] "http://plex" {})
(proxy ["mus"] "http://navidrome" enableWebsockets)
(proxy ["px1"] "https://proxmox" enableWebsockets)
(proxy ["py"] "http://jupyter" enableWebsockets)
(proxy ["vpn"] "http://headscale" enableWebsockets)