Skip to content

👑 darkone.admin.fleet-update

Fleet update tool (fleet-update) and its unattended daily run.

enable installs the tool on a deployment host; just fleet-update then runs it. timer.enable adds a daily fleet-update --no-ui run: flake update, build, test by waves, switch.

  • enable bool fleet-update, the fleet update and deployment tool

  • package package The fleet-update package. Its nix-eval-jobs is matched to the system Nix: the tool evaluates the consumer flake with it.

  • aiPackages listOf package AI tools reachable from the unattended run (--ai-model). Optional: the tool warns and goes on without AI when none is found.

    Not a dependency of the package, because pkgs.claude-code is unfree and would force allowUnfree on every consumer. pkgs.opencode is MIT.

  • aiContext nullOr str Operator guidance (language, style) included in every AI prompt of a run on this host, just fleet-update and the timer alike. Written to /etc/fleet-update/ai-context, even without enable: in co-development the recipe runs the sources. --ai-context, on the command line or in timer.extraArgs, overrides it.

  • user nullOr str Account running the unattended update: owner of workDir, holding the git identity, the sops age key and the AI and Matrix credentials.

  • workDir str Consumer workspace on disk. Not the workDir module argument, which is its copy in the nix store.

  • timer.enable bool the daily unattended run (fleet-update --no-ui)

  • timer.onCalendar str When the run starts (systemd OnCalendar).

  • timer.extraArgs listOf str Options passed after --no-ui, which the module always sets.

  • timer.timeout str Longest run before systemd stops it (TimeoutStartSec). A hung run would otherwise hold the lock, and every later run would exit 4 without any alert.

darkone.admin.fleet-update = {
enable = false;
package = pkgs.fleet-update.override { nix-eval-jobs = nixEvalJobs; };
aiPackages = [ ];
aiContext = "Answer in French and keep the response concise.";
user = "admin";
workDir = "/etc/nixos";
timer.enable = false;
timer.onCalendar = "*-*-* 04:00";
timer.extraArgs = [ ];
timer.timeout = "6h";
};

Source: modules/admin/fleet-update.nix 🡕