1{
2 lib,
3 buildGoModule,
4 fetchFromGitHub,
5 testers,
6 wireproxy,
7}:
8
9buildGoModule rec {
10 pname = "wireproxy";
11 version = "1.0.10";
12
13 src = fetchFromGitHub {
14 owner = "pufferffish";
15 repo = "wireproxy";
16 rev = "v${version}";
17 hash = "sha256-F8WatQsXgq3ex2uAy8eoS2DkG7uClNwZ74eG/mJN83o=";
18 };
19
20 ldflags = [
21 "-s"
22 "-w"
23 "-X main.version=v${version}"
24 ];
25
26 vendorHash = "sha256-uCU5WLCKl5T4I1OccVl7WU0GM/t4RyAEmzHkJ22py30=";
27
28 passthru.tests.version = testers.testVersion {
29 package = wireproxy;
30 command = "wireproxy --version";
31 version = src.rev;
32 };
33
34 meta = with lib; {
35 description = "Wireguard client that exposes itself as a socks5 proxy";
36 homepage = "https://github.com/pufferffish/wireproxy";
37 license = licenses.isc;
38 maintainers = with maintainers; [ _3JlOy-PYCCKUi ];
39 mainProgram = "wireproxy";
40 };
41}