Salamek / gitlab-tools

Web application providing tools not avaiable in GitLab CE (Gitlab push/pull mirror and more)
GNU General Public License v3.0
99 stars 15 forks source link

Accept public key of gitlab server #13

Closed Findus23 closed 6 years ago

Findus23 commented 6 years ago

This took me a while to debug and I am still not completely sure what the issue is.

On every mirror I got the following error:

Jul 22 18:59:58 vServer gitlab-tools[8600]: git.exc.GitCommandError: Cmd('git') failed due to: exit code(128)                                                                 
Jul 22 18:59:58 vServer gitlab-tools[8600]:   cmdline: git push --mirror --porcelain gitlab                                                                                   
Jul 22 18:59:58 vServer gitlab-tools[8600]:   stderr: 'fatal: Could not read from remote repository.                                                                          
Jul 22 18:59:58 vServer gitlab-tools[8600]: Please make sure you have the correct access rights                                                                               
Jul 22 18:59:58 vServer gitlab-tools[8600]: and the repository exists.'                                                                                                       

Then I had the idea to login as and then cd repositories/1/pull/2/9/ and run git push --mirror gitlab manually. After accepting the Are you sure you want to continue connecting (yes/no)? yes the push worked.

And afterwards all pushes from gitlab-tools also worked. I guess the known_hosts entry was missing.

Salamek commented 6 years ago

@Findus23 This should be handled by JavaScript (Do you have JavaScript enabled in browser?) modal when adding new mirror (for both sides): screenshot_2018-07-22_20-14-48

and trusted fingerprints should be shown in "Fingerprints" section of menu

Salamek commented 6 years ago

@Findus23 i just tested this on fresh install and everything seems to work as intended, i added noscript warning to make ~sure ppl will have it enabled in commit 7f951ba8bd1c12f5cb187dd2cf5f88a81fdde3f7.

Findus23 commented 6 years ago

@Salamek Thanks for testing. I have enabled JS and I thought I have already answered the modal.

Guess this isn't reproducible.