git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #170566 from bdd/pkg/new/runitor

runitor: init at 0.9.2

commitdc99b0d228c0cbae09bdb3827bbd97d86d7f833c authorGraham Christensen <graham@grahamc.com> dateWed 4 May 2022, 20:52 (5 years ago) parent1db9450c25b749
3 files changed+60
maintainers/maintainer-list.nix+6 pkgs/tools/system/runitor/default.nix+52 pkgs/top-level/all-packages.nix+2
maintainers/maintainer-list.nix+6
@@ -1409,6 +1409,12 @@
14091409 githubId = 164148;
14101410 name = "Ben Darwin";
14111411 };
1412+ bdd = {
1413+ email = "bdd@mindcast.org";
1414+ github = "bdd";
1415+ githubId = 11135;
1416+ name = "Berk D. Demir";
1417+ };
14121418 bdesham = {
14131419 email = "benjamin@esham.io";
14141420 github = "bdesham";
pkgs/tools/system/runitor/default.nixnew file+52
@@ -0,0 +1,52 @@
1+{ lib, buildGoModule, fetchFromGitHub, testers, runitor }:
2+
3+buildGoModule rec {
4+ pname = "runitor";
5+ version = "0.9.2";
6+ vendorSha256 = null;
7+
8+ src = fetchFromGitHub {
9+ owner = "bdd";
10+ repo = "runitor";
11+ rev = "v${version}";
12+ sha256 = "sha256-LuCxn4j0MlnJjSh3d18YNzNrtbqtMPxgkZttqKUGJd4";
13+ };
14+
15+ ldflags = [
16+ "-s" "-w" "-X main.Version=v${version}"
17+ ];
18+
19+ # TODO(cole-h):
20+ # End-to-end tests requiring localhost networking currently under
21+ # OfBorg's Linux builders, while passing under Darwin.
22+ #
23+ # Ref: https://github.com/NixOS/nixpkgs/pull/170566#issuecomment-1114034891
24+ #
25+ # Temporarily disable tests.
26+ doCheck = false;
27+
28+ passthru.tests.version = testers.testVersion {
29+ package = runitor;
30+ command = "runitor -version";
31+ version = "v${version}";
32+ };
33+
34+ # Unit tests require binding to local addresses for listening sockets.
35+ __darwinAllowLocalNetworking = true;
36+
37+ meta = with lib; {
38+ homepage = "https://bdd.fi/x/runitor";
39+ description = "A command runner with healthchecks.io integration";
40+ longDescription = ''
41+ Runitor runs the supplied command, captures its output, and based on its exit
42+ code reports successful or failed execution to https://healthchecks.io or your
43+ private instance.
44+
45+ Healthchecks.io is a web service for monitoring periodic tasks. It's like a
46+ dead man's switch for your cron jobs. You get alerted if they don't run on time
47+ or terminate with a failure.
48+ '';
49+ license = licenses.bsd0;
50+ maintainers = with maintainers; [ bdd ];
51+ };
52+}
pkgs/top-level/all-packages.nix+2
@@ -34473,6 +34473,8 @@ with pkgs;
3447334473
3447434474 runit = callPackage ../tools/system/runit { };
3447534475
34476+ runitor = callPackage ../tools/system/runitor { };
34477+
3447634478 refind = callPackage ../tools/bootloaders/refind { };
3447734479
3447834480 spectrojack = callPackage ../applications/audio/spectrojack { };