2021-01-15 22:18:51 +00:00
|
|
|
{ lib, stdenv
|
2020-04-24 23:36:52 +00:00
|
|
|
, fetchFromGitHub
|
|
|
|
, autoreconfHook
|
|
|
|
, pkg-config
|
|
|
|
, glib
|
|
|
|
, libcap
|
|
|
|
, libseccomp
|
|
|
|
, libslirp
|
2020-05-29 06:06:01 +00:00
|
|
|
, nixosTests
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "slirp4netns";
|
2021-03-09 03:18:52 +00:00
|
|
|
version = "1.1.9";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "rootless-containers";
|
|
|
|
repo = "slirp4netns";
|
|
|
|
rev = "v${version}";
|
2021-03-09 03:18:52 +00:00
|
|
|
sha256 = "sha256-jUxAkC9nMiDiHKyKtmdtOEyb9jqOEiy5D3NqymluX28=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ autoreconfHook pkg-config ];
|
|
|
|
|
|
|
|
buildInputs = [ glib libcap libseccomp libslirp ];
|
|
|
|
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
2020-09-25 04:45:31 +00:00
|
|
|
passthru.tests = { inherit (nixosTests) podman; };
|
2020-05-29 06:06:01 +00:00
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://github.com/rootless-containers/slirp4netns";
|
|
|
|
description = "User-mode networking for unprivileged network namespaces";
|
|
|
|
license = licenses.gpl2;
|
|
|
|
maintainers = with maintainers; [ orivej ] ++ teams.podman.members;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|