2021-11-23 16:43:56 +00:00
|
|
|
{ lib
|
|
|
|
, fetchFromGitHub
|
|
|
|
, buildGoModule
|
|
|
|
, stayrtr
|
2022-04-20 14:40:48 +00:00
|
|
|
, testers
|
2021-11-23 16:43:56 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "stayrtr";
|
2023-03-02 18:01:39 +00:00
|
|
|
version = "0.5.1";
|
2021-11-23 16:43:56 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "bgp";
|
|
|
|
repo = "stayrtr";
|
|
|
|
rev = "v${version}";
|
2023-03-02 18:01:39 +00:00
|
|
|
hash = "sha256-/KwL/SEnHquFhPcYXpvQs71W4K1BrbqTPakatTNF47Q=";
|
2021-11-23 16:43:56 +00:00
|
|
|
};
|
2023-03-02 18:01:39 +00:00
|
|
|
vendorHash = "sha256-ndMME9m3kbv/c1iKlU2Pn/YoiRQy7jfVQri3M+qhujk=";
|
|
|
|
|
|
|
|
patches = [
|
|
|
|
./go.mod.patch
|
|
|
|
];
|
2021-11-23 16:43:56 +00:00
|
|
|
|
|
|
|
ldflags = [
|
|
|
|
"-s"
|
|
|
|
"-w"
|
|
|
|
"-X main.version=${version}"
|
|
|
|
];
|
|
|
|
|
2022-04-20 14:40:48 +00:00
|
|
|
passthru.tests.version = testers.testVersion {
|
2021-11-23 16:43:56 +00:00
|
|
|
package = stayrtr;
|
|
|
|
};
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Simple RPKI-To-Router server. (Hard fork of GoRTR)";
|
|
|
|
homepage = "https://github.com/bgp/stayrtr/";
|
|
|
|
license = licenses.bsd3;
|
|
|
|
maintainers = with maintainers; [ _0x4A6F ];
|
|
|
|
};
|
|
|
|
}
|