Bug #5215

gitCheckout uses SSH even when SSH does not work (in particular ways)

Added by Gianluca Petrillo over 7 years ago. Updated about 7 years ago.

Target version:
Start date:
Due date:
% Done:


Estimated time:


I premise than I don't know the underlying reasons for the choice of the
following code, so I might well be writing something silly.

I read in
the function run_git_command().

It chooses between SSH and HTTP, according to the outcome of the test greeting:

ssh p-${rbase} "echo Hi"

If it finds "Permission" in the output (could be "Permission denied"; or
"Permission granted"), then it goes SSH.

When I try to use it from my laptop to check out "larsim":

$ ssh "echo Hi" 
Permission denied (publickey,gssapi-keyex,gssapi-with-mic)

it slams the door on my face, maybe because p-larsim user does not exist, so it
chooses HTTP.
When I try to check out 'larsoft':

$ ssh "echo Hi" 
Connection closed by

it still slams the door on my face in a different way (I am not sure why, that's
another problem), but doesn't smell "Permission" denial and tries to use SSH
(which of course fails). My problem would be solved by a different check, like:
if ! ssh p-${rbase} "echo Hi" >& /dev/null ; then
    ##echo "you do not have read-write permissions for the repository" 

or similar.


#1 Updated by Lynn Garren about 7 years ago

  • Status changed from New to Feedback
  • Assignee set to Lynn Garren

Apologies for missing this. Had to set the new issue alert.

Is this still a problem for you? If so, please tell us a) what OS you see this problem on and b) exactly what you type that when you see the problem.

Please talk to us before trying to solve something like this yourself so you can avoid chasing a red herring, which is apparently what you attempted.

#2 Updated by Lynn Garren about 7 years ago

  • Status changed from Feedback to Resolved

The immediate issue was resolved by giving Gianluca the appropriate write access.

#3 Updated by Lynn Garren about 7 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF