liminix

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit 7c9c801afc03b4838153f795c1d1ead4a6e0b067
parent c4185617c039dacfe1afdc6b051c9507069fa99f
Author: Daniel Barlow <dan@telent.net>
Date:   Sun, 16 Jun 2024 12:58:06 +0100

rename isTrigger to restart-on-upgrade

we're moving away from "trigger" services to "controller" services,
and "restart-on-upgrade" is the name used by s6-rc

Diffstat:
Mmodules/ifwait/ifwait.nix | 2+-
Mmodules/service-trigger/rule.nix | 2+-
Mpkgs/liminix-tools/services/default.nix | 6+++---
3 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/modules/ifwait/ifwait.nix b/modules/ifwait/ifwait.nix @@ -9,7 +9,7 @@ let in longrun { name = "ifwait.${interface.name}"; buildInputs = [ service ]; - isTrigger = true; + restart-on-upgrade = true; run = '' ${ifwait}/bin/ifwait -s ${service.name} $(output ${interface} ifname) ${state} ''; diff --git a/modules/service-trigger/rule.nix b/modules/service-trigger/rule.nix @@ -19,6 +19,6 @@ let termsString = stringify terms; in longrun { name = "watch-for-${serviceName}"; - isTrigger = true; + restart-on-upgrade = true; run = "${uevent-watch}/bin/uevent-watch ${if symlink != null then "-n ${symlink}" else ""} -s ${serviceName} ${termsString}"; } diff --git a/pkgs/liminix-tools/services/default.nix b/pkgs/liminix-tools/services/default.nix @@ -38,15 +38,15 @@ let , dependencies ? [] , contents ? [] , buildInputs ? [] - , isTrigger ? false + , restart-on-upgrade ? false , controller ? null } @ args: stdenvNoCC.mkDerivation { # we use stdenvNoCC to avoid generating derivations with names # like foo.service-mips-linux-musl inherit name serviceType up down run finish notification-fd - producer-for consumer-for pipeline-name timeout-up timeout-down; - restart-on-upgrade = isTrigger; + producer-for consumer-for pipeline-name timeout-up timeout-down + restart-on-upgrade; buildInputs = buildInputs ++ dependencies ++ contents ++ lib.optional (controller != null) controller; inherit controller dependencies contents; builder = ./builder.sh;