nixos/grafana-agent: use lib.getExe
as binary names changed between updates
and `lib.getExe` allows a safe handling and potential backport of this. But for that to work it would require 22.11 to set `pkgs.grafana-agent.meta.mainProgram = "agent"` Relevant upstream release: https://github.com/grafana/agent/releases/tag/v0.31.0
This commit is contained in:
parent
bde538be9f
commit
845a6e9784
1 changed files with 1 additions and 1 deletions
|
@ -140,7 +140,7 @@ in
|
|||
# We can't use Environment=HOSTNAME=%H, as it doesn't include the domain part.
|
||||
export HOSTNAME=$(< /proc/sys/kernel/hostname)
|
||||
|
||||
exec ${cfg.package}/bin/agent -config.expand-env -config.file ${configFile}
|
||||
exec ${lib.getExe cfg.package} -config.expand-env -config.file ${configFile}
|
||||
'';
|
||||
serviceConfig = {
|
||||
Restart = "always";
|
||||
|
|
Loading…
Reference in a new issue