Skip to content

Commit e87f54c

Browse files
authored
kubevpn: 2.2.10 -> 2.3.9 (#375096)
2 parents 5a7c064 + dfc7253 commit e87f54c

File tree

1 file changed

+31
-4
lines changed

1 file changed

+31
-4
lines changed

pkgs/by-name/ku/kubevpn/package.nix

Lines changed: 31 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,27 +2,54 @@
22
lib,
33
buildGoModule,
44
fetchFromGitHub,
5+
go,
56
}:
67

78
buildGoModule rec {
89
pname = "kubevpn";
9-
version = "2.2.10";
10+
version = "2.3.9";
1011

1112
src = fetchFromGitHub {
1213
owner = "KubeNetworks";
1314
repo = "kubevpn";
1415
rev = "v${version}";
15-
hash = "sha256-2LDV2aVdGuclVmOgIIwMYRKTMVLzlmNFI6xHFpxMRJw=";
16+
hash = "sha256-g/N9Ho+s2AEA4iQSK48KGoTgsEMqv8ya3ZqCAhgVInc=";
1617
};
1718

1819
vendorHash = null;
1920

20-
# TODO investigate why some config tests are failing
21-
doCheck = false;
21+
tags = [
22+
"noassets" # required to build synthing gui without generating assets
23+
];
24+
25+
ldflags = [
26+
"-X github.com/wencaiwulue/kubevpn/v2/pkg/config.Version=v${version}"
27+
"-X github.com/wencaiwulue/kubevpn/v2/cmd/kubevpn/cmds.OsArch=${go.GOOS}/${go.GOARCH}"
28+
];
29+
30+
# Resolve configuration tests, which access $HOME
31+
preCheck = ''
32+
export HOME=$(mktemp -d)
33+
'';
34+
35+
# Disable network tests
36+
checkFlags = [
37+
"-skip=^Test(Route|Functions|ByDumpClusterInfo|ByCreateSvc|Elegant)$"
38+
];
39+
40+
doInstallCheck = true;
41+
42+
installCheckPhase = ''
43+
runHook preInstallCheck
44+
$out/bin/kubevpn help
45+
$out/bin/kubevpn version | grep -e "Version: v${version}"
46+
runHook postInstallCheck
47+
'';
2248

2349
meta = with lib; {
2450
changelog = "https://github.com/KubeNetworks/kubevpn/releases/tag/${src.rev}";
2551
description = "Create a VPN and connect to Kubernetes cluster network, access resources, and more";
52+
mainProgram = "kubevpn";
2653
homepage = "https://github.com/KubeNetworks/kubevpn";
2754
license = licenses.mit;
2855
maintainers = with maintainers; [ mig4ng ];

0 commit comments

Comments
 (0)