fix: scope deploy output redirect to git-hook only
The previous condition used a bash regex `git-*` that matched git-receive-pack and git-upload-pack, interposing a tee chain on the binary git wire protocol and producing `fatal: protocol error: bad line length character: !` on every push. Restrict the redirect to the pre-receive hook, where tee passthrough is safe because git-receive-pack forwards hook output via the protocol sideband.
This commit is contained in:
2
dokku
2
dokku
@@ -188,7 +188,7 @@ execute_dokku_cmd() {
|
|||||||
set -- "$PLUGIN_CMD" "$@"
|
set -- "$PLUGIN_CMD" "$@"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ $PLUGIN_NAME =~ git-* ]] || [[ "$PLUGIN_NAME" == "ps:rebuild" ]] || [[ "$PLUGIN_NAME" == "ps:restart" ]] || [[ "$PLUGIN_NAME" == "deploy" ]]; then
|
if [[ "$PLUGIN_NAME" == "git-hook" ]] || [[ "$PLUGIN_NAME" == "ps:rebuild" ]] || [[ "$PLUGIN_NAME" == "ps:restart" ]] || [[ "$PLUGIN_NAME" == "deploy" ]]; then
|
||||||
export DOKKU_REDIRECT_OUTPUT=true
|
export DOKKU_REDIRECT_OUTPUT=true
|
||||||
exec &> >(tee >(tee | logger -i -t "dokku-${DOKKU_PID}"))
|
exec &> >(tee >(tee | logger -i -t "dokku-${DOKKU_PID}"))
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user