Issue 2421: Replication fails to create new repository on remote that does not allow ssh shell
Status:  New
Owner: ----
Project Member Reported by david.pu...@sonymobile.com, Jan 23, 2014
************************************************************
***** NOTE: THIS BUG TRACKER IS FOR GERRIT CODE REVIEW *****
***** DO NOT SUBMIT BUGS FOR CHROME, ANDROID, INTERNAL *****
***** ISSUES WITH YOUR COMPANY'S GERRIT SETUP, ETC.    *****
***** THOSE ISSUE BELONG IN DIFFERENT ISSUE TRACKERS!  *****
************************************************************

Affected Version: 2.8.1

What steps will reproduce the problem?
1. Set up replication to a remote that does not support ssh shell, for example gitlab.
2. Create a new project on the master
3. Observe the logs

What is the expected output? What do you see instead?

With [1] I can see that the replication plugin "successfully" creates the new repository on the remote.  However the repository is not actually created.  Then on the next replication it tries to create again, but doesn't find it, and tries again to create.  This goes on indefinitely.

On the command line opening an ssh connection to the gitlab instance fails with an error message that the TTY connection was not possible, but the process exits with 0 status indicating no error.  That's probably why the replication plugins assumes success.

Maybe it would be better to add a step afterwards to verify that it was created.



[1] https://gerrit-review.googlesource.com/#/c/53992/


Please provide any additional information below.

Jan 27, 2014
Project Member #1 david.pu...@sonymobile.com
This is caused by the fact that the gitlab ssh shell does not return an error for commands that are not allowed.  See [1] for bug report on gitlab shell.

As a workaround it might be worth adding a check in the replication plugin to confirm that the project was created.

[1] https://github.com/gitlabhq/gitlab-shell/issues/127