From db2201b8f655dd7bc7a0729512d23193d2998bdc Mon Sep 17 00:00:00 2001 From: Kris Kennaway Date: Sun, 26 Sep 2004 22:37:22 +0000 Subject: [PATCH] Support ${client_user} and ${sudo_cmd} for running commands as root on machines where we first connect to a non-root user and then increase privileges. Approved by: portmgr (self) --- Tools/portbuild/scripts/allgohans | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Tools/portbuild/scripts/allgohans b/Tools/portbuild/scripts/allgohans index 391a8a60bc12..2caa379809a6 100755 --- a/Tools/portbuild/scripts/allgohans +++ b/Tools/portbuild/scripts/allgohans @@ -14,10 +14,14 @@ doarch() { machines=$(awk '{print $1}' ${pb}/${arch}/mlist) for i in ${machines}; do + . ${pb}/${arch}/portbuild.conf + if [ -f "${pb}/${arch}/portbuild.${i}" ]; then + . ${pb}/${arch}/portbuild.${i} + fi if [ ${quiet} -eq 0 ]; then echo "[$i]" fi - su ports-${arch} -c "ssh root@$i $@" + su ports-${arch} -c "ssh ${client_user}@$i ${sudo_cmd} $@" done }