mirror of
https://github.com/srid/nixos-config.git
synced 2026-05-11 00:55:58 +08:00
agenix: fix restart loop
Ref: https://github.com/ryantm/agenix/pull/352
This commit is contained in:
parent
330fa8a390
commit
97322e9d9a
1 changed files with 12 additions and 1 deletions
|
|
@ -1,7 +1,7 @@
|
|||
# Debug agenix logs:
|
||||
# cat ~/Library/Logs/agenix/stdout
|
||||
# cat ~/Library/Logs/agenix/stderr
|
||||
{ flake, config, ... }:
|
||||
{ flake, config, lib, ... }:
|
||||
let
|
||||
inherit (flake.inputs) agenix;
|
||||
in
|
||||
|
|
@ -16,4 +16,15 @@ in
|
|||
# To provision this key once:
|
||||
# ssh-keygen -t ed25519 -f ~/.ssh/agenix
|
||||
age.identityPaths = [ "${config.home.homeDirectory}/.ssh/agenix" ];
|
||||
|
||||
# WORKAROUND: Fix agenix restart loop on Darwin
|
||||
# See: https://github.com/ryantm/agenix/issues/308
|
||||
# Permanent fix pending in: https://github.com/ryantm/agenix/pull/352
|
||||
#
|
||||
# The issue: `Crashed = false` means "restart when NOT crashed" (i.e., restart on successful exit)
|
||||
# This causes the agent to restart every 10 seconds after successful completion.
|
||||
# Solution: Remove the Crashed option entirely, only keep SuccessfulExit = false
|
||||
launchd.agents.activate-agenix.config.KeepAlive = lib.mkForce {
|
||||
SuccessfulExit = false;
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue