Merge pull request #93680 from xoe-labs/da-kube3d-update

kube3d 1.7.0 -> 3.0.0
This commit is contained in:
Timo Kaufmann 2020-07-28 13:03:19 +02:00 committed by GitHub
commit 09e7fb1d5c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,24 +1,33 @@
{ stdenv, buildGoModule, fetchFromGitHub }:
{ stdenv, buildGoModule, fetchFromGitHub, installShellFiles }:
buildGoModule rec {
pname = "kube3d";
version = "1.7.0";
k3sVersion = "1.17.3-k3s1";
version = "3.0.0";
k3sVersion = "1.18.6-k3s1";
goPackagePath = "github.com/rancher/k3d";
excludedPackages = ''tools'';
src = fetchFromGitHub {
owner = "rancher";
repo = "k3d";
rev = "v${version}";
sha256 = "0aij2l7zmg4cxbw7pwf7ddc64di25hpjvbmp1madhz9q28rwfa9w";
sha256 = "1p4rqzi67cr8vf1ih7zqxkpssqq0vy4pb5crvkxbbf5ad5mwrjri";
};
buildFlagsArray = ''
-ldflags=
-w -s
-X github.com/rancher/k3d/version.Version=${version}
-X github.com/rancher/k3d/version.K3sVersion=v${k3sVersion}
-X github.com/rancher/k3d/v3/version.Version=v${version}
-X github.com/rancher/k3d/v3/version.K3sVersion=v${k3sVersion}
'';
nativeBuildInputs = [ installShellFiles ];
postInstall = ''
for shell in bash zsh; do
$out/bin/k3d completion $shell > k3d.$shell
installShellCompletion k3d.$shell
done
'';
vendorSha256 = null;