nur-packages

My NUR packages
git clone git://git.sikmir.ru/nur-packages
Log | Files | Refs | README | LICENSE

commit 60766ad7238ab2fcf3008ce7f541416a96050922
parent c9a433f92628eeab17f460c3c8ebfab925365a03
Author: Nikolay Korotkiy <sikmir@disroot.org>
Date:   Sat, 13 Jul 2024 12:17:00 +0400

Add mochi

Diffstat:
Mpkgs/default.nix | 1+
Apkgs/mqtt/mochi/default.nix | 31+++++++++++++++++++++++++++++++
2 files changed, 32 insertions(+), 0 deletions(-)

diff --git a/pkgs/default.nix b/pkgs/default.nix @@ -406,6 +406,7 @@ lib.makeScope newScope ( ioxy = callPackage ./mqtt/ioxy { }; janus-mqtt-proxy = callPackage ./mqtt/janus-mqtt-proxy { }; libumqtt = callPackage ./mqtt/libumqtt { }; + mochi = callPackage ./mqtt/mochi { }; mongoose = callPackage ./mqtt/mongoose { }; mproxy = callPackage ./mqtt/mproxy { }; mqcontrol = callPackage ./mqtt/mqcontrol { }; diff --git a/pkgs/mqtt/mochi/default.nix b/pkgs/mqtt/mochi/default.nix @@ -0,0 +1,31 @@ +{ + lib, + fetchFromGitHub, + buildGoModule, +}: + +buildGoModule rec { + pname = "mochi"; + version = "2.6.4"; + + src = fetchFromGitHub { + owner = "mochi-mqtt"; + repo = "server"; + rev = "v${version}"; + hash = "sha256-oQDxagj4+am6DNfdZB1iHwlfFW0Q/b4Sq8YiP5sVqWM="; + }; + + vendorHash = "sha256-+28spfekUVTDCvDgmKXpHNRQNAlQ4k9lEU4H6gZu9ZI="; + + postInstall = '' + mv $out/bin/{cmd,mochi} + mv $out/bin/{docker,mochi-docker} + ''; + + meta = { + description = "The fully compliant, embeddable high-performance Go MQTT v5 server for IoT, smarthome, and pubsub"; + homepage = "https://github.com/mochi-mqtt/server"; + license = lib.licenses.mit; + maintainers = [ lib.maintainers.sikmir ]; + }; +}