commit f3fb1d8ca2ca5197b56a88fc4299c62eb4c81ea0
parent ea269b1192c7ded5b16647922db9ed9711f17b13
Author: Vincent Demeester <vincent@sbr.pm>
Date: Thu, 17 Dec 2020 16:30:45 +0100
pkgs: add buildx v0.5.1
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Diffstat:
3 files changed, 34 insertions(+), 0 deletions(-)
diff --git a/flake.nix b/flake.nix
@@ -286,6 +286,8 @@
manifest-tool = pkgs.callPackage ./pkgs/manifest-tool { };
ko = pkgs.callPackage ./pkgs/ko { };
+ buildx = pkgs.callPackage ./pkgs/buildx { };
+ buildkit = pkgs.callPackage ./pkgs/buildkit { };
} // optionalAttrs (system == "x86_64-linux") {
# OpenShift
inherit (pkgs.callPackage ./pkgs/oc { })
diff --git a/pkgs/buildx/default.nix b/pkgs/buildx/default.nix
@@ -0,0 +1,31 @@
+{ stdenv, lib, fetchFromGitHub, buildGoModule }:
+
+buildGoModule rec {
+ name = "buildx-${version}";
+ version = "0.5.1";
+ rev = "v${version}";
+
+ goPackagePath = "github.com/docker/buildx";
+ subPackages = [ "cmd/buildx" ];
+
+ buildFlagsArray = let t = "${goPackagePath}/version"; in
+ ''
+ -ldflags=
+ -X ${t}.Version=${version}
+ '';
+
+ src = fetchFromGitHub {
+ inherit rev;
+ owner = "docker";
+ repo = "buildx";
+ sha256 = "0l03ncs1x4lhgy0kf7bd1zq00md8fi93f8xq6k0ans4400divfzk";
+ };
+ vendorSha256 = null;
+ doCheck = false;
+
+ meta = {
+ description = "Docker CLI plugin for extended build capabilities with buildkit";
+ homepage = https://github.com/docker/buildx;
+ license = lib.licenses.asl20;
+ };
+}
diff --git a/pkgs/default.nix b/pkgs/default.nix
@@ -115,6 +115,7 @@ rec {
# Upstream
buildkit = pkgs.callPackage ./buildkit { };
+ buildx = pkgs.callPackage ./buildx { };
inherit (pkgs.callPackage ./containerd { })
containerd_1_2
containerd_1_3