From 68a0395d9aabebf2fa90c5481847f2532f259f4f Mon Sep 17 00:00:00 2001 From: Dominik Polakovics Date: Thu, 5 Feb 2026 12:49:24 +0100 Subject: [PATCH 1/2] fix: update invidious with overlay to fix an issue --- utils/overlays/packages.nix | 56 +++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) diff --git a/utils/overlays/packages.nix b/utils/overlays/packages.nix index e3bfebd..25a59b8 100644 --- a/utils/overlays/packages.nix +++ b/utils/overlays/packages.nix @@ -18,5 +18,61 @@ self: super: { pyload-ng = self.callPackage ../pkgs/pyload-ng { pyload-ng = super.pyload-ng; }; + # TODO: Remove this override once nixpkgs includes invidious >= 2.20250204 with PR #5614 fix + # Fix for 400 errors on channel lists - https://github.com/iv-org/invidious/pull/5614 + invidious = + let + version = "unstable-2026-02-04"; + commit = "ecbc21b"; + date = "2026.02.04"; + src = super.fetchFromGitHub { + owner = "iv-org"; + repo = "invidious"; + rev = "ecbc21b0678eac4a0c8f745de5cc78eef4841221"; + fetchSubmodules = true; + hash = "sha256-S6/d1Fzv3CrZHBW3aE21OoPUeQwEFFMwkeJyUKyTcGQ="; + }; + # Fetch videojs dependencies - reuse existing hash as dependencies are unlikely to change + videojs = super.stdenvNoCC.mkDerivation { + name = "videojs"; + inherit src; + builder = "${super.path}/pkgs/by-name/in/invidious/videojs.sh"; + nativeBuildInputs = with super; [ cacert crystal_1_16 openssl pkg-config ]; + outputHashAlgo = "sha256"; + outputHashMode = "recursive"; + outputHash = "sha256-jED3zsDkPN8i6GhBBJwnsHujbuwlHdsVpVqa1/pzSH4="; + }; + in + super.invidious.overrideAttrs (oldAttrs: { + inherit version src; + postPatch = let + branchTemplate = ''{{ "#{`git branch | sed -n '/* /s///p'`.strip}" }}''; + commitTemplate = ''{{ "#{`git rev-list HEAD --max-count=1 --abbrev-commit`.strip}" }}''; + versionTemplate = ''{{ "#{`git log -1 --format=%ci | awk '{print $1}' | sed s/-/./g`.strip}" }}''; + tagTemplate = ''{{ "#{`git tag --points-at HEAD`.strip}" }}''; + assetCommitTemplate = ''{{ "#{`git rev-list HEAD --max-count=1 --abbrev-commit -- assets`.strip}" }}''; + in '' + for d in ${videojs}/*; do ln -s "$d" assets/videojs; done + + substituteInPlace src/invidious.cr \ + --replace-fail ${super.lib.escapeShellArg branchTemplate} '"master"' \ + --replace-fail ${super.lib.escapeShellArg commitTemplate} '"${commit}"' \ + --replace-fail ${super.lib.escapeShellArg versionTemplate} '"${date}"' \ + --replace-fail ${super.lib.escapeShellArg tagTemplate} '""' \ + --replace-fail ${super.lib.escapeShellArg assetCommitTemplate} '"${commit}"' + + substituteInPlace src/invidious.cr \ + --replace-fail 'public_folder "assets"' 'public_folder "${placeholder "out"}/share/invidious/assets"' + substituteInPlace src/invidious/helpers/i18n.cr \ + --replace-fail 'File.read("locales/' 'File.read("${placeholder "out"}/share/invidious/locales/' + + substituteInPlace src/invidious/database/base.cr \ + --replace-fail 'config/sql' '${placeholder "out"}/share/invidious/config/sql' + + substituteInPlace src/invidious/user/captcha.cr \ + --replace-fail 'Process.run(%(rsvg-convert' 'Process.run(%(${super.lib.getBin super.librsvg}/bin/rsvg-convert' + ''; + }); + # vscode-insiders = (super.callPackage ../pkgs/vscode-insiders.nix { }); } From 3c34e87a808afac96cdd55d10c4d848e07388f90 Mon Sep 17 00:00:00 2001 From: Dominik Polakovics Date: Thu, 5 Feb 2026 12:49:41 +0100 Subject: [PATCH 2/2] fix: add overlay to web module --- hosts/fw/modules/web/default.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hosts/fw/modules/web/default.nix b/hosts/fw/modules/web/default.nix index 31e742c..dfc77fd 100644 --- a/hosts/fw/modules/web/default.nix +++ b/hosts/fw/modules/web/default.nix @@ -15,6 +15,9 @@ in { "n8n" ]; }; + overlays = [ + (import ../../utils/overlays/packages.nix) + ]; }; config = { microvm = {