gitlab-shell -> git push -u origin master -> fatal: The remote end hung up unexpectedly
git, gitlab, ssh
Solution
I've tried this : $ ssh -vT git@git.my-srv.fr
I've see in the log an http redirect 301. (my proxy server redirect http to https)
I've correct it in gitlab-shell config, file : /home/git/gitlab-shell/config.yml
# Url to gitlab instance. Used for api calls
gitlab_url: "https://git.my-srv.fr/"
the new error message was a ssl certificate verification fail (my certificate is auto-signed with no 3rd part autority)
so i've modified /home/git/gitlab-shell/lib/gitlab_net.rb to add this :
http.verify_mode = OpenSSL::SSL::VERIFY_NONE if (http.use_ssl?)
between these lines :
http.use_ssl = (url.port == 443)
http.verify_mode = OpenSSL::SSL::VERIFY_NONE if (http.use_ssl?)
request = Net::HTTP::Get.new(url.request_uri)
Like describe on this gitlab-shell closed pull request (and issue) : https://github.com/gitlabhq/gitlab-shell/pull/9
And here is the original commit content : https://github.com/jcockhren/gitlab-shell/commit/846ee24697f386cd9fcbc4ab1a7fb8ae1ccb46ee
Problem
I'm using gitlab-shell to manage git connections and here is my problem : ``` $ git push -v -u origin master Pushing to git@git.my-srv.fr:monProjet.git fatal: The remote end hung up unexpectedly ``` ``` # tail -f /var/log/auth.log Mar 15 15:53:12 my-srv sshd[3133]: Accepted publickey for git from my-ip port 50790 ssh2 Mar 15 15:53:12 my-srv sshd[3133]: pam_unix(sshd:session): session opened for user git by (uid=0) Mar 15 15:53:12 my-srv sshd[3285]: Received disconnect from my-ip: 11: disconnected by user Mar 15 15:53:12 my-srv sshd[3133]: pam_unix(sshd:session): session closed for user git ``` So everybody say it's the other fault?! How can I have more informations about the git/ssh network exchange?