I tried the workaround but it doesn't work. I put this in /etc/default/git-daemon:
export GIT_CONFIG_COUNT=1 export GIT_CONFIG_KEY_0=safe.directory export GIT_CONFIG_VALUE_0="*" Then reinstalled 2.39.5-0+deb12u1 and confirmed with htop the environment variables are set for git-daemon. But "git clone" fails: fatal: unable to access '...': The requested URL returned error: 500 Johannes