We've used /usr/bin/timeout for a while for this, to make the gitbuilder not hang even when Github goes for a coffee break, but I just realized you already include maxtime so this is doable without external dependencies, so I'm submitting this pull request now.
(Now, whether that should be 60 seconds or something else is debatable. And should it be configurable? But the need is definitely there.)
make git remote update time out after 60 seconds
Signed-off-by: Sage Weil <firstname.lastname@example.org>
Signed-off-by: Tommi Virtanen <email@example.com>