From 2e582d4edc753613cf4af77814440831a5c97785 Mon Sep 17 00:00:00 2001 From: Gaetan Lepage Date: Mon, 5 Jun 2023 08:32:17 +0200 Subject: [PATCH] nixos/invidious: add automaticRestart option --- nixos/modules/services/web-apps/invidious.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/nixos/modules/services/web-apps/invidious.nix b/nixos/modules/services/web-apps/invidious.nix index 61c52ee03dc6..e875be47fb91 100644 --- a/nixos/modules/services/web-apps/invidious.nix +++ b/nixos/modules/services/web-apps/invidious.nix @@ -41,6 +41,12 @@ let RestrictNamespaces = true; SystemCallArchitectures = "native"; SystemCallFilter = [ "@system-service" "~@privileged" "~@resources" ]; + + # Because of various issues Invidious must be restarted often, at least once a day, ideally + # every hour. + # This option enables the automatic restarting of the Invidious instance. + Restart = lib.mkDefault "always"; + RuntimeMaxSec = lib.mkDefault "1h"; }; };