Skip to content

Commit

Permalink
Merge pull request #170613 from NickCao/tun2socks
Browse files Browse the repository at this point in the history
tun2socks: init at 2.4.1
  • Loading branch information
SuperSandro2000 authored Apr 27, 2022
2 parents 941c24d + ad1f6eb commit 24b4077
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 0 deletions.
31 changes: 31 additions & 0 deletions pkgs/tools/networking/tun2socks/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
{ lib
, buildGoModule
, fetchFromGitHub
}:

buildGoModule rec {
pname = "tun2socks";
version = "2.4.1";

src = fetchFromGitHub {
owner = "xjasonlyu";
repo = pname;
rev = "v${version}";
sha256 = "sha256-FBYRqxS8DJbIc8j8X6WNxl6a1YRcNrPSnNfrq/Y0fMM=";
};

vendorSha256 = "sha256-XWzbEtYd8h63QdpAQZTGxyxMAAnpKO9Fp4y8/eeZ7Xw=";

ldflags = [
"-w" "-s" "-buildid="
"-X github.com/xjasonlyu/tun2socks/v2/internal/version.Version=v${version}"
"-X github.com/xjasonlyu/tun2socks/v2/internal/version.GitCommit=v${version}"
];

meta = with lib; {
homepage = "https://github.com/xjasonlyu/tun2socks";
description = "tun2socks - powered by gVisor TCP/IP stack";
license = licenses.gpl3Plus;
maintainers = with maintainers; [ nickcao ];
};
}
4 changes: 4 additions & 0 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -10953,6 +10953,10 @@ with pkgs;

trytond = with python3Packages; toPythonApplication trytond;

tun2socks = callPackage ../tools/networking/tun2socks {
buildGoModule = buildGo118Module;
};

tuntox = callPackage ../tools/networking/tuntox { };

omapd = callPackage ../tools/security/omapd { };
Expand Down

0 comments on commit 24b4077

Please sign in to comment.