2023-11-16 04:20:00 +00:00
|
|
|
{ lib
|
|
|
|
, buildGoModule
|
|
|
|
, fetchFromGitHub
|
|
|
|
, python3
|
|
|
|
, bash
|
|
|
|
, coreutils
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "supercronic";
|
2024-07-27 06:49:29 +00:00
|
|
|
version = "0.2.30";
|
2023-11-16 04:20:00 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "aptible";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2024-07-27 06:49:29 +00:00
|
|
|
hash = "sha256-gey5d+Dxmk7TS0miWRjeWMxW+qYrAPVYGHcHNYrYwK4=";
|
2023-11-16 04:20:00 +00:00
|
|
|
};
|
|
|
|
|
2024-07-27 06:49:29 +00:00
|
|
|
vendorHash = "sha256-ebUsnPpvQ/AK3C7MbGnXWSiuoXrjhQ2uZhj1OtRGeWU=";
|
2023-11-16 04:20:00 +00:00
|
|
|
|
|
|
|
excludedPackages = [ "cronexpr/cronexpr" ];
|
|
|
|
|
|
|
|
nativeCheckInputs = [ python3 bash coreutils ];
|
|
|
|
|
|
|
|
postConfigure = ''
|
|
|
|
# There are tests that set the shell to various paths
|
|
|
|
substituteInPlace cron/cron_test.go --replace /bin/sh ${bash}/bin/sh
|
|
|
|
substituteInPlace cron/cron_test.go --replace /bin/false ${coreutils}/bin/false
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Cron tool designed for use in containers";
|
|
|
|
homepage = "https://github.com/aptible/supercronic";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ nasageek ];
|
2024-01-02 11:29:13 +00:00
|
|
|
mainProgram = "supercronic";
|
2023-11-16 04:20:00 +00:00
|
|
|
};
|
|
|
|
}
|