问题
I know git supports SSH. But my 13-year old server does not support SSH. Only telnet is supported.
Is it possible to push to a git repository over telnet?
How to setup such environment?
回答1:
No, it isn't possible.
Even 13 years ago telnet wasn't an acceptable protocol to use, and ssh was already supported by any server worth using. That's even more the case now.
You may be able to set up support for doing git over http, including pushes. But you should really see about getting something that can support ssh.
回答2:
Use the git ext:: protocol handler https://git-scm.com/docs/git-remote-ext or set GIT_SSH to your remote shell and emulate the SSH options (to build the emulation script you can simply adapt e.g. Execute remote commands from Debian to Windows via Telnet)
See this post on how git communicates using git-upload-pack: https://unix.stackexchange.com/questions/140089/what-commands-does-git-use-when-communicating-via-ssh
来源:https://stackoverflow.com/questions/15287934/git-over-telnet