depot/third_party/nixpkgs/pkgs/tools/networking/hysteria/default.nix
Default email 2c76a4cb41 Project import generated by Copybara.
GitOrigin-RevId: c757e9bd77b16ca2e03c89bf8bc9ecb28e0c06ad
2023-11-16 04:20:00 +00:00

39 lines
841 B
Nix

{ lib
, fetchFromGitHub
, buildGoModule
}:
buildGoModule rec {
pname = "hysteria";
version = "2.2.0";
src = fetchFromGitHub {
owner = "apernet";
repo = pname;
rev = "app/v${version}";
hash = "sha256-v9W1/1AIcYKYxVnFFXZdwQC50FWJCMQ0OXCmlfmXWQk=";
};
vendorHash = "sha256-/lFDCOkwkBKq1GJA1F7Lyhw++X1G1pld6JXNEdKue/E=";
proxyVendor = true;
ldflags = [
"-s"
"-w"
"-X main.appVersion=${version}"
];
postInstall = ''
mv $out/bin/app $out/bin/hysteria
'';
# Network required
doCheck = false;
meta = with lib; {
description = "A feature-packed proxy & relay utility optimized for lossy, unstable connections";
homepage = "https://github.com/apernet/hysteria";
license = licenses.mit;
platforms = platforms.linux;
maintainers = with maintainers; [ oluceps ];
};
}