From 3e446ecd564611953c75caf97a855285ef30ba38 Mon Sep 17 00:00:00 2001 From: Rodney Lorrimar Date: Mon, 2 Apr 2018 11:30:24 +0100 Subject: nixos/buildkite-agent: fix variable expansion in hook scripts @cleverca found this bug in the declarative hooks config. Any shell variables referenced in a hook script would get expanded by the hooks directory builder. Prevent variable expansion by quoting the here doc limit string. --- nixos/modules/services/continuous-integration/buildkite-agent.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nixos/modules/services/continuous-integration/buildkite-agent.nix b/nixos/modules/services/continuous-integration/buildkite-agent.nix index 03af9a7859ec..d647b7b9fa49 100644 --- a/nixos/modules/services/continuous-integration/buildkite-agent.nix +++ b/nixos/modules/services/continuous-integration/buildkite-agent.nix @@ -17,7 +17,7 @@ let hooksDir = let mkHookEntry = name: value: '' - cat > $out/${name} < $out/${name} <<'EOF' #! ${pkgs.runtimeShell} set -e ${value} -- cgit 1.4.1