Create SVN repository on Synology

Howto install SVN on your Synology: http://forum.synology.com/wiki/index.php/Step-by-step_guide_to_installing_Subversion

Telnet to your NAS
Repositories has to be owned by svnowner; be sure to execute creation of the repository as svnowner (or chown afterwards):

$>su svnowner

On the synolyg your harddisk is mounten at /volume1; create a directory “svn” here:

cd /volume1
mkdir svn
cd svn

Now create your SVN repository with the svnadmin command (on the synology the svn command is not on the path but can be found at /opt/bin):

/opt/bin/svnadmin create test

If you want to delete a repository you can do this with regular unix commands; there is no “internal” SVN registration.

Now you have to setup the access to this new repository. Change directory to your new repository conf folder:
cd /volume1/svn/test/conf

The svnadmin command has stored some default files here; passwd and svnserve.conf. First edit the passwd file to add your users for this repository. Below the [users] text add your users.

Now edit the svnserve.conf in the same folder. Disable anonymous access to your repository by adding: anon-access = none

To use the password file for authentication of your users you have to uncomment the password-db = passwd line.

That’s all you have to do on your synology. SVN is setup (see link) and the repository is created with appropriate user access..

Now go to your client machine and checkout the new repository:

svn co svn://[your hostname here]/test

Check the status of your local repository copy:

svn status

Add a file to your repository

svn add newfile

And commit the file to the repository

svn commit newfile

 

 

 

 

Share

Leave a Reply

Your email address will not be published. Required fields are marked *