about summary refs log tree commit diff
path: root/pkgs/applications/networking/cluster/kompose
diff options
context:
space:
mode:
authorAaron Jheng <wentworth@outlook.com>2022-04-04 14:35:00 +0000
committerAaron Jheng <wentworth@outlook.com>2022-04-04 14:35:00 +0000
commite40b63c1da1a8d6134f06242f2f67e97d7a871c0 (patch)
tree48816702d6beeb6e4ee41a384672aabeabdb3522 /pkgs/applications/networking/cluster/kompose
parent1a069f4e72b179f07cef6178f85dfc15eed5e321 (diff)
kompose: 1.21.0 -> 1.26.1
Diffstat (limited to 'pkgs/applications/networking/cluster/kompose')
-rw-r--r--pkgs/applications/networking/cluster/kompose/default.nix24
1 files changed, 17 insertions, 7 deletions
diff --git a/pkgs/applications/networking/cluster/kompose/default.nix b/pkgs/applications/networking/cluster/kompose/default.nix
index c01e1c8c00417..517ab55d9d2d9 100644
--- a/pkgs/applications/networking/cluster/kompose/default.nix
+++ b/pkgs/applications/networking/cluster/kompose/default.nix
@@ -1,19 +1,24 @@
-{ lib, buildGoPackage, fetchFromGitHub, installShellFiles }:
+{ lib, buildGoModule, fetchFromGitHub, installShellFiles, testVersion, kompose }:
 
-buildGoPackage rec {
+buildGoModule rec {
   pname = "kompose";
-  version = "1.21.0";
-
-  goPackagePath = "github.com/kubernetes/kompose";
+  version = "1.26.1";
 
   src = fetchFromGitHub {
-    rev = "v${version}";
     owner = "kubernetes";
     repo = "kompose";
-    sha256 = "15a1alf6ywwfc4z5kdcnv64fp3cfy3qrcw62ny6xyn1kh1w24vkh";
+    rev = "v${version}";
+    sha256 = "sha256-NfzqGG5ZwPpmjhvcvXN1AA+kfZG/oujbAEtXkm1mzeU=";
   };
 
+  vendorSha256 = "sha256-OR5U2PnebO0a+lwU09Dveh0Yxk91cmSRorTxQIO5lHc=";
+
   nativeBuildInputs = [ installShellFiles ];
+
+  ldflags = [ "-s" "-w" ];
+
+  checkFlags = [ "-short" ];
+
   postInstall = ''
     for shell in bash zsh; do
       $out/bin/kompose completion $shell > kompose.$shell
@@ -21,6 +26,11 @@ buildGoPackage rec {
     done
   '';
 
+  passthru.tests.version = testVersion {
+    package = kompose;
+    command = "kompose version";
+  };
+
   meta = with lib; {
     description = "A tool to help users who are familiar with docker-compose move to Kubernetes";
     homepage = "https://kompose.io";