depot/third_party/nixpkgs/pkgs/applications/virtualization/conmon/default.nix
Default email 889482aab3 Project import generated by Copybara.
GitOrigin-RevId: f2537a505d45c31fe5d9c27ea9829b6f4c4e6ac5
2022-06-26 12:26:21 +02:00

45 lines
1,017 B
Nix

{ lib
, stdenv
, fetchFromGitHub
, pkg-config
, glib
, glibc
, libseccomp
, systemd
, nixosTests
}:
stdenv.mkDerivation rec {
pname = "conmon";
version = "2.1.2";
src = fetchFromGitHub {
owner = "containers";
repo = pname;
rev = "v${version}";
sha256 = "sha256-KDAm+Djk1AaA3zXhxywT6HknT0tVCEZLS27nO9j/WgM=";
};
nativeBuildInputs = [ pkg-config ];
buildInputs = [ glib libseccomp systemd ]
++ lib.optionals (!stdenv.hostPlatform.isMusl) [ glibc glibc.static ];
# manpage requires building the vendored go-md2man
makeFlags = [ "bin/conmon" ];
installPhase = ''
runHook preInstall
install -D bin/conmon -t $out/bin
runHook postInstall
'';
passthru.tests = { inherit (nixosTests) cri-o podman; };
meta = with lib; {
homepage = "https://github.com/containers/conmon";
description = "An OCI container runtime monitor";
license = licenses.asl20;
maintainers = with maintainers; [ ] ++ teams.podman.members;
platforms = platforms.linux;
};
}