2021-10-01 03:50:30 +01:00
|
|
|
{ lib, buildGoModule, fetchFromGitHub }:
|
2021-05-08 07:00:09 +01:00
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "multus-cni";
|
2021-09-18 11:23:45 +01:00
|
|
|
version = "3.8";
|
2021-05-08 07:00:09 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "k8snetworkplumbingwg";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2021-09-18 11:23:45 +01:00
|
|
|
sha256 = "sha256-wG6SRts3+bmeMkfScyNorsBvRl/hxe+CUnL0rwfknpc=";
|
2021-05-08 07:00:09 +01:00
|
|
|
};
|
|
|
|
|
2021-10-01 03:50:30 +01:00
|
|
|
ldflags = [
|
|
|
|
"-s"
|
|
|
|
"-w"
|
|
|
|
"-X=gopkg.in/k8snetworkplumbingwg/multus-cni.v3/pkg/multus.version=${version}"
|
2021-05-08 07:00:09 +01:00
|
|
|
];
|
|
|
|
|
|
|
|
preInstall = ''
|
2021-10-01 03:50:30 +01:00
|
|
|
mv $GOPATH/bin/cmd $GOPATH/bin/multus
|
2021-05-08 07:00:09 +01:00
|
|
|
'';
|
|
|
|
|
|
|
|
vendorSha256 = null;
|
|
|
|
|
|
|
|
# Some of the tests require accessing a k8s cluster
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
meta = with lib; {
|
2021-10-01 03:50:30 +01:00
|
|
|
description = "Multus CNI is a container network interface (CNI) plugin for Kubernetes that enables attaching multiple network interfaces to pods";
|
2021-05-08 07:00:09 +01:00
|
|
|
homepage = "https://github.com/k8snetworkplumbingwg/multus-cni";
|
|
|
|
license = licenses.asl20;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
maintainers = with maintainers; [ onixie ];
|
2021-10-01 03:50:30 +01:00
|
|
|
mainProgram = "multus";
|
2021-05-08 07:00:09 +01:00
|
|
|
};
|
|
|
|
}
|