at 23.05-pre 1.0 kB view raw
1{ lib, stdenv, buildGoModule, fetchFromGitHub, git, Virtualization, testers, linuxkit }: 2 3buildGoModule rec { 4 pname = "linuxkit"; 5 version = "1.0.1"; 6 7 src = fetchFromGitHub { 8 owner = "linuxkit"; 9 repo = "linuxkit"; 10 rev = "v${version}"; 11 sha256 = "sha256-8x9oJaYb/mN2TUaVrGOYi5/6TETD78jif0SwCSc0kyo="; 12 }; 13 14 vendorSha256 = null; 15 16 modRoot = "./src/cmd/linuxkit"; 17 18 buildInputs = lib.optionals stdenv.isDarwin [ Virtualization ]; 19 20 ldflags = [ 21 "-s" 22 "-w" 23 "-X github.com/linuxkit/linuxkit/src/cmd/linuxkit/version.Version=${version}" 24 ]; 25 26 checkInputs = [ git ]; 27 28 passthru.tests.version = testers.testVersion { 29 package = linuxkit; 30 command = "linuxkit version"; 31 }; 32 33 meta = with lib; { 34 description = "A toolkit for building secure, portable and lean operating systems for containers"; 35 license = licenses.asl20; 36 homepage = "https://github.com/linuxkit/linuxkit"; 37 maintainers = with maintainers; [ nicknovitski ]; 38 platforms = platforms.unix; 39 }; 40}