Reputation: 3135
First of all I have just an one day experience with svn so sorry if my question is too simple to ask. Here is my question: while I've searched on the net I realized that the following code block creates the repository for me.
$ sudo mkdir /home/svn
$ cd /home/svn
$ sudo mkdir myproject
The SVN repository can be created using the following command:
$ sudo svnadmin create /home/svn/myproject
And use the following commands to correct file permissions:
$ cd /home/svn
$ sudo chown -R www-data:subversion myproject
$ sudo chmod -R g+rws myproject
I'm fine with these lines except the one
$ sudo chown -R www-data:subversion myproject
According to what I learned, it changes the ownership status of myproject
from root
to www-data:subversion
. However, I don't understand why it is necessary and what is www-data
. By the way I'm using linux.
Upvotes: 1
Views: 2661
Reputation: 12110
www-data
is the default username of apache service in some linux distros.
In many default installations, subversion is served by apache
server. apache
cannot serve file which he has no access to. Therefore, you should change the ownership of the repo to www-data
.
Upvotes: 1