Ubuntu 24.04
Sponsored Link

Subversion : Remote Access to Repositories2024/07/24

 

Access to Repositories from remote Hosts.

[1] Start [svnserve] on a Host that Subversion repository exists.
# create a directory for repositories on any pace you like and start [svnserve]

root@dlp:~#
mkdir /var/svn

root@dlp:~#
svnserve --daemon --pid-file /run/svnserve.pid --root /var/svn
# create a test project

root@dlp:~#
mkdir -p /var/svn/repos/project

root@dlp:~#
svnadmin create /var/svn/repos/project

root@dlp:~#
svn mkdir file:///var/svn/repos/project/trunk -m "create"

root@dlp:~#
svn mkdir file:///var/svn/repos/project/branches -m "create"

root@dlp:~#
svn mkdir file:///var/svn/repos/project/tags -m "create"

[2] Access to existing Subversion repository from another remote Host.
For example, Access to existing [/var/svn/repos/project] repository.
By the way, default access permission is read only, so it's impossible to execute [commit] or others like changing operation. For changing operation from remote Host, it needs to set access permission like the link.
# specify relative path name for SVN URI
# on this example
# SVN Top directory : [/var/svn]
# SVN repository directory : [/var/svn/repos/project]
# relative path : [repos/project]
# SVN URI : [svn://dlp.srv.world/repos/project]

ubuntu@node01:~$
svn list svn://dlp.srv.world/repos/project

branches/
tags/
trunk/

ubuntu@node01:~$
mkdir ./work

ubuntu@node01:~$
svn checkout svn://dlp.srv.world/repos/project ./work

A    work/branches
A    work/tags
A    work/trunk
Checked out revision 3.

ubuntu@node01:~$
ll work

total 24
drwxrwxr-x 6 ubuntu ubuntu 4096 Jul 24 03:43 ./
drwxrwxr-x 3 ubuntu ubuntu 4096 Jul 24 03:43 ../
drwxrwxr-x 4 ubuntu ubuntu 4096 Jul 24 03:43 .svn/
drwxrwxr-x 2 ubuntu ubuntu 4096 Jul 24 03:43 branches/
drwxrwxr-x 2 ubuntu ubuntu 4096 Jul 24 03:43 tags/
drwxrwxr-x 2 ubuntu ubuntu 4096 Jul 24 03:43 trunk/
[3] It's also possible to access via SSH without running [svnserve] service on Subversion Host.
ubuntu@node01:~$
svn ls svn+ssh://ubuntu@dlp.srv.world/var/svn/repos/project

ubuntu@dlp.srv.world's password:
branches/
tags/
trunk/

ubuntu@node01:~$
mkdir ./work2

ubuntu@node01:~$
svn co svn+ssh://ubuntu@dlp.srv.world/var/svn/repos/project ./work2

ubuntu@dlp.srv.world's password:
A    work2/branches
A    work2/tags
A    work2/trunk
Checked out revision 3.
Matched Content