50 ms·
Speaking of http tricks I'm more impressed about how you can clone github URLs (i.e. they serve git and regular http on the same port).
by rjh29 4y ago
Speaking of http tricks I'm more impressed about how you can clone github URLs (i.e. they serve git and regular http on the same port).
- andix 4y agoIsn’t there a git over HTTP protocol? Even if your git server is different to your http server, you can just reverse-proxy it behind your HTTP server.
- ElfinTrousers 4y agoYes I haven't seen anyone use it for some time but the `git+https` scheme used to be common.
- oefrha 4y agoWhen you git clone https://github.com/git/git https://github.com/git/git, the git client simply GET https://github.com/git/git/info/refs?service=git-upload-pack https://github.com/git/git/info/refs?service=git-upload-pack etc. Nothing magical, there’s not even content negotiation involved. git:// protocol uses port 9481 by default, so not the same port.
- rjh29 4y agoThanks.
- yamtaddle 4y agoOthers note that git supports http clone, but if you do want to serve SSH and HTTP on the same port, that's something haproxy makes pretty easy to do. It's not something terribly fancy, these days.