nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at devShellTools-shell 67 lines 1.4 kB view raw
1{ 2 lib, 3 rustPlatform, 4 fetchFromGitHub, 5 pkg-config, 6 installShellFiles, 7 getconf, 8 dbus, 9 libseccomp, 10 systemd, 11 stdenv, 12}: 13 14rustPlatform.buildRustPackage rec { 15 pname = "youki"; 16 version = "0.5.4"; 17 18 src = fetchFromGitHub { 19 owner = "containers"; 20 repo = "youki"; 21 rev = "v${version}"; 22 hash = "sha256-tWe5EPodO+slp+K7mn9UTVApNdiDRPMsOa9RfiT9qQw="; 23 }; 24 25 nativeBuildInputs = [ 26 pkg-config 27 installShellFiles 28 getconf 29 ]; 30 31 buildInputs = [ 32 dbus 33 libseccomp 34 systemd 35 ]; 36 37 postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) '' 38 installShellCompletion --cmd youki \ 39 --bash <($out/bin/youki completion -s bash) \ 40 --fish <($out/bin/youki completion -s fish) \ 41 --zsh <($out/bin/youki completion -s zsh) 42 ''; 43 44 cargoBuildFlags = [ 45 "-p" 46 "youki" 47 "--features" 48 "systemd" 49 ]; 50 51 cargoTestFlags = [ 52 "-p" 53 "youki" 54 ]; 55 56 cargoHash = "sha256-YM4D2DDXc9o4ak2DT36IeXpYykA/9R7PPqmIXkZ9aDs="; 57 58 meta = { 59 description = "Container runtime written in Rust"; 60 homepage = "https://containers.github.io/youki/"; 61 changelog = "https://github.com/containers/youki/releases/tag/v${version}"; 62 license = lib.licenses.asl20; 63 maintainers = with lib.maintainers; [ builditluc ]; 64 platforms = lib.platforms.linux; 65 mainProgram = "youki"; 66 }; 67}