From e6fb8a4224ecf6e44c96bc8e6a3b010cb7de2536 Mon Sep 17 00:00:00 2001 From: Graham Christensen Date: Wed, 18 Sep 2024 23:18:28 -0400 Subject: [PATCH] amazon-ssm-agent: add the system's software to the path Follow up to #342584. Similarly to that PR, it is surprising that software which was installed by the user isn't available to a script run over ssm by default. When executing commands with ssm, users will now have more predictable access to baked-in software instead of an extremely bare-minimum set currently there. (cherry picked from commit 7547a1f5f862cc013fca1712dfbf300ed86c8161) --- nixos/modules/services/misc/amazon-ssm-agent.nix | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/nixos/modules/services/misc/amazon-ssm-agent.nix b/nixos/modules/services/misc/amazon-ssm-agent.nix index 9ab4a7f96d08..2d22df8e9328 100644 --- a/nixos/modules/services/misc/amazon-ssm-agent.nix +++ b/nixos/modules/services/misc/amazon-ssm-agent.nix @@ -45,7 +45,12 @@ in { after = [ "network-online.target" ]; wantedBy = [ "multi-user.target" ]; - path = [ fake-lsb-release pkgs.coreutils ]; + path = [ + fake-lsb-release + pkgs.coreutils + "/run/wrappers" + "/run/current-system/sw" + ]; serviceConfig = { ExecStart = "${cfg.package}/bin/amazon-ssm-agent";