about summary refs log tree commit diff
path: root/nixpkgs/pkgs/tools/security/aws-iam-authenticator/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/tools/security/aws-iam-authenticator/default.nix')
-rw-r--r--nixpkgs/pkgs/tools/security/aws-iam-authenticator/default.nix28
1 files changed, 28 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/tools/security/aws-iam-authenticator/default.nix b/nixpkgs/pkgs/tools/security/aws-iam-authenticator/default.nix
new file mode 100644
index 000000000000..b1f5d8b56c30
--- /dev/null
+++ b/nixpkgs/pkgs/tools/security/aws-iam-authenticator/default.nix
@@ -0,0 +1,28 @@
+{ lib, buildGoModule, fetchFromGitHub }:
+
+buildGoModule rec {
+  pname = "aws-iam-authenticator";
+  version = "0.5.5";
+
+  src = fetchFromGitHub {
+    owner = "kubernetes-sigs";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "sha256-5QtNAcInp1mUE8SHUUMS8/XURbPx/q8xMsvEEo/rnCs=";
+  };
+
+  # Upstream has inconsistent vendoring, see https://github.com/kubernetes-sigs/aws-iam-authenticator/issues/377
+  deleteVendor = true;
+  vendorSha256 = null;
+
+  ldflags = [ "-s" "-w" "-X main.version=v${version}" ];
+
+  subPackages = [ "cmd/aws-iam-authenticator" ];
+
+  meta = with lib; {
+    homepage = "https://github.com/kubernetes-sigs/aws-iam-authenticator";
+    description = "AWS IAM credentials for Kubernetes authentication";
+    license = licenses.asl20;
+    maintainers = [ maintainers.srhb ];
+  };
+}