nixpkgs/pkgs/applications/networking/cluster/dnsname-cni/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

43 lines
925 B
Nix
Raw Normal View History

{
buildGoModule,
dnsmasq,
fetchFromGitHub,
lib,
nixosTests,
makeWrapper,
}:
2021-05-24 11:29:16 +00:00
buildGoModule rec {
pname = "cni-plugin-dnsname";
2021-08-20 18:15:27 +00:00
version = "1.3.1";
2021-05-24 11:29:16 +00:00
src = fetchFromGitHub {
owner = "containers";
repo = "dnsname";
rev = "v${version}";
2021-08-20 18:15:27 +00:00
sha256 = "sha256-kebN1OLMOrBKBz4aBV0VYm+LmLm6S0mKnVgG2u5I+d4=";
2021-05-24 11:29:16 +00:00
};
nativeBuildInputs = [ makeWrapper ];
postInstall = ''
wrapProgram $out/bin/dnsname --prefix PATH : ${lib.makeBinPath [ dnsmasq ]}
2021-05-24 11:29:16 +00:00
'';
vendorSha256 = null;
subPackages = [ "plugins/meta/dnsname" ];
doCheck = false; # NOTE: requires root privileges
2021-05-27 14:22:28 +00:00
passthru.tests = {
inherit (nixosTests) podman-dnsname;
};
2021-05-24 11:29:16 +00:00
meta = with lib; {
description = "DNS name resolution for containers";
homepage = "https://github.com/containers/dnsname";
license = licenses.asl20;
platforms = platforms.linux;
maintainers = with maintainers; [ mikroskeem ];
};
}