commit
a67259409a
|
@ -1,4 +1,10 @@
|
|||
{ buildGoModule, fetchFromGitHub, installShellFiles, lib }:
|
||||
{ lib
|
||||
, buildGoModule
|
||||
, fetchFromGitHub
|
||||
, installShellFiles
|
||||
, testers
|
||||
, karmor
|
||||
}:
|
||||
|
||||
buildGoModule rec {
|
||||
pname = "karmor";
|
||||
|
@ -15,6 +21,13 @@ buildGoModule rec {
|
|||
|
||||
nativeBuildInputs = [ installShellFiles ];
|
||||
|
||||
ldflags = [
|
||||
"-s"
|
||||
"-w"
|
||||
"-X=github.com/kubearmor/kubearmor-client/selfupdate.BuildDate=1970-01-01"
|
||||
"-X=github.com/kubearmor/kubearmor-client/selfupdate.GitSummary=${version}"
|
||||
];
|
||||
|
||||
# integration tests require network access
|
||||
doCheck = false;
|
||||
|
||||
|
@ -26,6 +39,13 @@ buildGoModule rec {
|
|||
--zsh <($out/bin/karmor completion zsh)
|
||||
'';
|
||||
|
||||
passthru.tests = {
|
||||
version = testers.testVersion {
|
||||
package = karmor;
|
||||
command = "karmor version || true";
|
||||
};
|
||||
};
|
||||
|
||||
meta = with lib; {
|
||||
description = "A client tool to help manage KubeArmor";
|
||||
homepage = "https://kubearmor.io";
|
||||
|
|
Loading…
Reference in a new issue