2023-11-16 04:20:00 +00:00
|
|
|
{ lib
|
|
|
|
, buildGoModule
|
|
|
|
, fetchFromGitHub
|
|
|
|
, nix-update-script
|
|
|
|
, testers
|
|
|
|
, mercure
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "mercure";
|
2024-09-19 14:19:46 +00:00
|
|
|
version = "0.16.3";
|
2023-11-16 04:20:00 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "dunglas";
|
|
|
|
repo = "mercure";
|
|
|
|
rev = "v${version}";
|
2024-09-19 14:19:46 +00:00
|
|
|
hash = "sha256-mRBnjX9jXo2yoftDo8F6kNZeddFkFyUQ6eWxWoxzk2w=";
|
2023-11-16 04:20:00 +00:00
|
|
|
};
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
sourceRoot = "${src.name}/caddy";
|
2023-11-16 04:20:00 +00:00
|
|
|
|
2024-09-19 14:19:46 +00:00
|
|
|
vendorHash = "sha256-ylPHBb/3lX9vwszyf7QzGPxGXE/Jt3cLKhsfmGMG8WM=";
|
2023-11-16 04:20:00 +00:00
|
|
|
|
|
|
|
subPackages = [ "mercure" ];
|
|
|
|
excludedPackages = [ "../cmd/mercure" ];
|
|
|
|
|
|
|
|
ldflags = [
|
|
|
|
"-s"
|
|
|
|
"-w"
|
|
|
|
"-X 'github.com/caddyserver/caddy/v2.CustomVersion=Mercure.rocks v${version} Caddy'"
|
|
|
|
];
|
|
|
|
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
passthru = {
|
|
|
|
updateScript = nix-update-script { };
|
|
|
|
tests.version = testers.testVersion {
|
|
|
|
version = "v${version}";
|
|
|
|
package = mercure;
|
|
|
|
command = "mercure version";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
meta = with lib; {
|
2024-06-20 14:57:18 +00:00
|
|
|
description = "Open, easy, fast, reliable and battery-efficient solution for real-time communications";
|
2023-11-16 04:20:00 +00:00
|
|
|
homepage = "https://github.com/dunglas/mercure";
|
|
|
|
changelog = "https://github.com/dunglas/mercure/releases/tag/v${version}";
|
|
|
|
license = licenses.agpl3Only;
|
|
|
|
maintainers = with maintainers; [ gaelreyrol ];
|
|
|
|
platforms = platforms.unix;
|
|
|
|
mainProgram = "mercure";
|
|
|
|
};
|
|
|
|
}
|