Skip to content

Commit 49bb423

Browse files
committed
azure: test: silence termination message when killing git-daemon(1)
In order to properly tear down the test environment, we will kill git-daemon(1) if we've exercised it. As git-daemon(1) is spawned as a background process, it is still owned by the shell and thus killing it later on will print a termination message to the shell's stderr, causing Azure to report it as an error. Fix this by disowning the background process.
1 parent fb03f02 commit 49bb423

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

azure-pipelines/test.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ if [ -z "$SKIP_GITDAEMON_TESTS" ]; then
8181
git init --bare "${GITDAEMON_DIR}/test.git"
8282
git daemon --listen=localhost --export-all --enable=receive-pack --base-path="${GITDAEMON_DIR}" "${GITDAEMON_DIR}" 2>/dev/null &
8383
GITDAEMON_PID=$!
84+
disown $GITDAEMON_PID
8485
fi
8586

8687
if [ -z "$SKIP_PROXY_TESTS" ]; then

0 commit comments

Comments
 (0)