2

I would like to know how to use the command git svn clone Path/To/Svn Path/To/Dir on a Jenkins slave.


The problem is the username and password used by the master to launch the command. It seems that the master is using a "SYSTEM" user with no password. Here's the output :


C:\jenkins\workspace\Tests>git svn clone Path/To/Svn Path/To/Dir 
Initialized empty Git repository in C:/jenkins/workspace/Tests/.git/
Authentication realm: <Server> CollabNet Subversion Repository
Password for 'SYSTEM': 
Authentication realm: <Server> CollabNet Subversion Repository
Username: Use of uninitialized value $ret in chomp at 
/mingw64/share/perl5/Git.pm line 596.
Use of uninitialized value in concatenation (.) or string at 
/mingw64/share/perl5/Git/SVN/Prompt.pm line 20.
Password for '': 
Can't create session: Unable to connect to a repository at URL 
'Path/To/Svn': Unexpected server error 500 'Internal Server Error' on 
'Path/To/Svn' at /mingw64/share/perl5/Git/SVN.pm line 148.

That user has no right in my SVN server. I've tried adding --username 'username' --password 'password' on the command or to change the ~/.subversion/servers file to save the authentification, but it didn't worked.

Do you have any ideas ?

Thanks.

Edit : Path/To/Svn is a network link : https://.

Emile
  • 592
  • 10
  • 36
  • When you clone `Path/To/Svn` do you mean that the repository is accessible locally, via a mounted filesystem? Make sure the FS is mounted and the repository is accessible. If not you need to access it over the network using `svn://` or `http://` protocols. – phd May 16 '18 at 16:34
  • It's a network link like https://. I've edited my question, Thanks. – Emile May 16 '18 at 16:50
  • Try `git svn clone https://username:password@server/path` – phd May 16 '18 at 19:02
  • Tried it and didn't worked ... the error output is : `Bad URL passed to RA layer` – Emile May 16 '18 at 20:12
  • Most probably an issue with too old SVN: https://stackoverflow.com/a/13865154/7976758 – phd May 16 '18 at 20:16
  • My git-svn version seems to be recent : `git-svn version 2.17.0.windows.1 (svn 1.9.7)` – Emile May 17 '18 at 13:16
  • @Emile did you find the answer of the above question? – devops Feb 05 '19 at 14:50

0 Answers0