diff options
author | Bryan Drewery <bryan@shatow.net> | 2021-11-20 04:01:54 +0300 |
---|---|---|
committer | Bryan Drewery <bryan@shatow.net> | 2021-11-20 04:01:54 +0300 |
commit | 04719b571fe147bf1a4b26faa27a89bf549e2fa0 (patch) | |
tree | f186533e6ccbff2ca71917ab9e8e688f222fe4ad /src | |
parent | dd3fe661d3f5f03df05879b90cbf03cbe0a0302c (diff) |
stop_builders: Don't try to wait on host /var/run pidfiles
Diffstat (limited to 'src')
-rwxr-xr-x | src/share/poudriere/common.sh | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/share/poudriere/common.sh b/src/share/poudriere/common.sh index 64d7f7af..ec20e80e 100755 --- a/src/share/poudriere/common.sh +++ b/src/share/poudriere/common.sh @@ -4612,9 +4612,11 @@ stop_builders() { # wait for the last running processes # the pidfiles may not contain an EOF newline so awk fixes that - find "${MASTER_DATADIR}/var/run/" -name "*.pid" -exec \ - awk '{print}' {} + | - xargs pwait -t 20 2>/dev/null || : + if [ -n "${MASTER_DATADIR}" ]; then + find "${MASTER_DATADIR}/var/run/" -name "*.pid" -exec \ + awk '{print}' {} + | + xargs pwait -t 20 2>/dev/null || : + fi if [ ${PARALLEL_JOBS} -ne 0 ]; then msg "Stopping ${PARALLEL_JOBS} builders" |