diff options
Diffstat (limited to 'pkgs/applications/networking/cluster/zarf/default.nix')
-rw-r--r-- | pkgs/applications/networking/cluster/zarf/default.nix | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/pkgs/applications/networking/cluster/zarf/default.nix b/pkgs/applications/networking/cluster/zarf/default.nix index e580dd7e6ff27..7a802dd351bf4 100644 --- a/pkgs/applications/networking/cluster/zarf/default.nix +++ b/pkgs/applications/networking/cluster/zarf/default.nix @@ -1,22 +1,26 @@ { lib , buildGoModule , fetchFromGitHub +, installShellFiles +, stdenv }: buildGoModule rec { pname = "zarf"; - version = "0.34.0"; + version = "0.37.0"; src = fetchFromGitHub { owner = "defenseunicorns"; repo = "zarf"; rev = "v${version}"; - hash = "sha256-o3sfvzUCCW7hwNDrWH1IiRyZHkVnxffJdLS8BqzD5Ng="; + hash = "sha256-GgvpBYFPH1corqNCA6NQCg6Rkbdez9mFwv5HlmOCKvE="; }; - vendorHash = "sha256-Co9xKC7J0WGoaYxa+YukrP+6aOuhweZyXaH5wD97ioA="; + vendorHash = "sha256-gLnUvNxuxrMu6i+b0jgindgcbGOA+tk4N5N4owGV7B8="; proxyVendor = true; + nativeBuildInputs = [ installShellFiles ]; + preBuild = '' mkdir -p build/ui touch build/ui/index.html @@ -26,6 +30,14 @@ buildGoModule rec { ldflags = [ "-s" "-w" "-X" "github.com/defenseunicorns/zarf/src/config.CLIVersion=${src.rev}" "-X" "k8s.io/component-base/version.gitVersion=v0.0.0+zarf${src.rev}" "-X" "k8s.io/component-base/version.gitCommit=${src.rev}" "-X" "k8s.io/component-base/version.buildDate=1970-01-01T00:00:00Z" ]; + postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) '' + export K9S_LOGS_DIR=$(mktemp -d) + installShellCompletion --cmd zarf \ + --bash <($out/bin/zarf completion --no-log-file bash) \ + --fish <($out/bin/zarf completion --no-log-file fish) \ + --zsh <($out/bin/zarf completion --no-log-file zsh) + ''; + meta = with lib; { description = "DevSecOps for Air Gap & Limited-Connection Systems. https://zarf.dev"; mainProgram = "zarf"; |