Eli,
Eli Zaretskii wrote:
> $ git push
> Counting objects: 4, done.
> Compressing objects: 100% (4/4), done.
> Writing objects: 100% (4/4), 482 bytes | 0 bytes/s, done.
> Total 4 (delta 3), reused 0 (delta 0)
> remote: 2025/06/21 04:54:16 socat[29895] E read(5, 0x561208e76120, 8192):
> Connection refused
> To git.savannah.gnu.org:/srv/git/emacs.git
> 075ebed..dd95447 master -> master
The error being reported is the socat one, right?
> remote: 2025/06/21 04:54:16 socat[29895] E read(5, 0x561208e76120, 8192):
> Connection refused
The git push otherwise succeeded okay?
That socat error is due to Corwin's post-receive.udp-syndicate hook
script.
wget
https://git.savannah.gnu.org/git/emacs.git/hooks/post-receive.udp-syndicate
The summary of it is this.
#!/bin/sh
PROJECT=emacs
DEST_ADDR=ws.comic.chat
DEST_PORT=17971
while read -r _oldrev newrev refname
do
# use rev-parse to extract the tag/branch name
context=$( git rev-parse --abbrev-ref $refname )
# bring back AUTHOR first and MESSAGE using log
author=$( git log $newrev -1 --pretty=format:'%ae' | cut -d '@' -f 1 |
tr -d '\n')
title="$( git log $newrev -1 --pretty=format:'%s' )"
# finally, send the message with netcat
printf '%s %s %s %s\n' "$PROJECT" "$context" "$newrev" "$author"
"$title" |
socat - udp:$DEST_ADDR:$DEST_PORT
done
The result is this error:
root@vcs2:/etc# echo foo | socat - udp:ws.comic.chat:17971
2025/07/06 17:34:10 socat[14330] E read(5, 0x55c58a39d2f0, 8192):
Connection refused
It's UDP so there shouldn't be a "connection". Additionally I think
socat needs the unidirectional mode -u option.
Corwin can you chase this down on your server?
Happy Hacking! :-)
Bob