fix: z2k deps + better ci

This commit is contained in:
fufsob committed 2026-10-18 05:19:40 +00:00
1 parent 9f7ad91f39
commit c39921a72c
8 files changed
+231 -40

No files matched your search

+2
View File
@@ -4,6 +4,7 @@ let
mkTgWsProxy = _args: import ./tg-ws-proxy.nix { inherit pkgs; };
zapret2 = import ./zapret2.nix { inherit pkgs; };
whitelist-bypass = import ./whitelist-bypass.nix { inherit pkgs; };
z2k-detect = import ./z2k-detect.nix { inherit pkgs; };
mkProxySuiteSupervisor = import ./proxy-suite-supervisor.nix {
lib = pkgs.lib;
inherit pkgs;
@@ -24,6 +25,7 @@ in
mkProxySuiteSupervisor
zapret2
whitelist-bypass
z2k-detect
;
tg-ws-proxy = mkTgWsProxy { };
}
+33
View File
@@ -0,0 +1,33 @@
# z2k-detect, the 16 KB cutoff probe's Go side, at the z2k rev flake.lock holds. It is
# built from its own checkout, not from the module's `z2k` input: a consumer that
# supplies its own z2k (lon, npins, `follows`) would otherwise change go.sum under the
# pinned vendorHash. It talks to the lists and Lua only through the TSV maps.
#
# The rev comes from flake.lock; scripts/update-pins.sh refreshes hash and vendorHash
# after a z2k bump. The rev in the name keeps a store that still holds the previous
# checkout from reusing it under a stale hash.
{ pkgs }:
let
locked = (pkgs.lib.importJSON ../flake.lock).nodes.z2k.locked;
shortRev = builtins.substring 0 7 locked.rev;
in
pkgs.buildGoModule (finalAttrs: {
pname = "z2k-detect";
version = "0-unstable-${shortRev}";
src = pkgs.fetchFromGitHub {
name = "z2k-detect-source-${shortRev}";
inherit (locked) owner repo rev;
sparseCheckout = [ "z2k-detect" ];
hash = "sha256-eagnkmLgZfa4Qc2UkhBHO721iWTdKnqzPGHKLcphJtY=";
};
sourceRoot = "${finalAttrs.src.name}/z2k-detect";
vendorHash = "sha256-9Qv6O6/8MP9N44GPSDULEV/NcrHdEC3YZmIQmpaa1nE=";
subPackages = [ "cmd/z2k-detect" ];
# Its tests open raw sockets and dial out.
doCheck = false;
meta.mainProgram = "z2k-detect";
})