nixfiles/hosts/hetzner-vm/services/invidious.nix

59 lines
1.5 KiB
Nix
Raw Normal View History

2022-05-09 09:03:00 +01:00
{ inputs, pkgs, ... }: {
2021-12-28 21:42:46 +00:00
services.invidious = {
enable = true;
2022-06-01 07:13:31 +01:00
#package =
# inputs.nixpkgs-stable.outputs.legacyPackages.${pkgs.system}.invidious;
2021-12-28 21:42:46 +00:00
port = 3000;
settings = {
full_refresh = true;
https_only = true;
2022-05-09 09:03:00 +01:00
popular_enabled = true;
2021-12-28 21:42:46 +00:00
statistics_enabled = true;
registration_enabled = true;
channel_threads = 2;
feed_threads = 2;
default_user_preferences = {
locale = "en-US";
region = "GB";
captions = [ "English (auto-generated)" "English" "" ];
dark_mode = true;
feed_menu = [ "Subscriptions" "Popular" ];
default_home = "Subscriptions";
max_results = 30;
annotations = true;
annotations_subscribed = true;
comments = [ ];
player_style = "invidious";
related_videos = true;
autoplay = true;
2022-05-09 09:03:00 +01:00
continue = true;
2021-12-28 21:42:46 +00:00
continue_autoplay = true;
quality = "hd720";
local = false;
};
2021-12-28 16:00:56 +00:00
};
2021-12-28 21:42:46 +00:00
};
systemd.services.invidious.serviceConfig = {
Restart = "always";
RuntimeMaxSec = "1200";
};
2022-05-17 13:17:02 +01:00
services.nginx.virtualHosts."invidious.owo.monster" = {
2021-12-28 21:42:46 +00:00
forceSSL = true;
enableACME = true;
locations = { "/".proxyPass = "http://127.0.0.1:3000"; };
};
2022-05-17 13:17:02 +01:00
services.nginx.virtualHosts."invidious-nojs.owo.monster" = {
forceSSL = true;
enableACME = true;
locations = {
"/".proxyPass = "http://127.0.0.1:3000";
"/js/".extraConfig = "deny all;";
};
};
2021-12-28 21:42:46 +00:00
#networking.firewall.allowedTCPPorts = [ 3000 ];
}