summaryrefslogtreecommitdiffstats
path: root/krebs/3modules
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2016-02-19 18:54:20 +0100
committertv <tv@krebsco.de>2016-02-20 02:02:08 +0100
commita60767166201066eea80b7f53fdcc2e623dc769a (patch)
tree5dbff2caf84a82780bcdbe7e689a93fc59b1aa54 /krebs/3modules
parent8f6892ef5b73230fab2fae58b969c00cd328d71f (diff)
krebs.build.populate: allow overriding ssh
Diffstat (limited to 'krebs/3modules')
-rw-r--r--krebs/3modules/build.nix6
1 files changed, 4 insertions, 2 deletions
diff --git a/krebs/3modules/build.nix b/krebs/3modules/build.nix
index b8ea34ae2..08a7cd047 100644
--- a/krebs/3modules/build.nix
+++ b/krebs/3modules/build.nix
@@ -41,6 +41,8 @@ let
#! /bin/sh
set -eu
+ ssh=''${ssh-ssh}
+
verbose() {
printf '%s%s\n' "$PS5$(printf ' %q' "$@")" >&2
"$@"
@@ -48,7 +50,7 @@ let
{ printf 'PS5=%q%q\n' @ "$PS5"
echo ${shell.escape git-script}
- } | verbose ssh -p ${shell.escape target-port} \
+ } | verbose $ssh -p ${shell.escape target-port} \
${shell.escape "${target-user}@${target-host}"} -T
unset tmpdir
@@ -77,7 +79,7 @@ let
) (attrNames source-by-method.file)} \
--delete \
-vFrlptD \
- -e ${shell.escape "ssh -p ${target-port}"} \
+ -e "$ssh -p ${shell.escape target-port}" \
${shell.escape target-path}/ \
${shell.escape "${target-user}@${target-host}:${target-path}"}
'';