Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi I'm investigating subversion at home, and my company is planning on migrating from cvs to subversion. I was wondering if there are any standard or recommended locations to put the subversion repository. Obviously you can put it anywhere, and I'm sure there are people who put it in different places for different reasons. But I'm sure there are a few standard spots that have reason for why they are there in the filesystem hierarchy.
The cvs manual seems to suggest /usr/local/cvsroot. I guess I could make a /usr/src/svnrepos. The subversion manual doesn't seem to get into setting up the repository location or give suggested locations.
In my home install I decided /var/svnrepos. (I'm using FC5 btw) I guess because a repository seems like variable data. Though after creating the repo, I can't add a project as user. I'm guessing I need to modify owner or group of the subversion repository directory and its subdirectories. For now I would like it so a group of admins could add projects and programmers could of course checkout, checkin and add new sources within an existing project.
Eventually I would like to setup remote access, and restricting certain projects to certain developers but I can do more research into those, and there appears to be more documentation on setting up remote access.
Distribution: debian, gentoo, os x (darwin), ubuntu
Posts: 940
Rep:
i personally use /var/svn or /var/lib/svn and create repositories in there
the reason for this is that the purpose of /var is for 'variable' data
whereas /usr if for 'user' data (hence /usr/local/bin for 'user appliactions')
if you check where other databases (subversion server uses berkleydb) have their root (mysql pgsql apt or yum) then you can follow that structure.
if you get into kernel compiling, you will also read that /urs/src is where you have software sources to compile (also kernel sources are installed here if you install using a package) - i don't think it would be the place for a databse.
Thanks Nathanael,
I agree that the var partition makes more sense. It seems most other databases exist in /var/lib even though I wouldn't really clasify db's as state information. There is a /var/db folder but doesn't seem to be used by much and it isn't even part of the FSH standard.
Any advice on the repository file permission stuff. I think I'll just try creating a group svnadmin and changing the directory group, as well as giving write permission to the group.
Distribution: debian, gentoo, os x (darwin), ubuntu
Posts: 940
Rep:
premissions depend on how you want to serve your repositories - if you want to use web_dev your webserver (most likley apache2) will require read and write premissions to your repositories.
if you want to use svnserve you can setup a new user and group, but make sure svnserv runs as that user!
I've been researching this pretty recently myself and got mine up just last week for "home files". I would say about 40% of web sites show the subversion directory in /home, such as:
/home/svn or /home/subversion.
The funny thing is I only have one problem I cannot figure out, and that's how to have the web browser show all the available repositories in that directory. I can see the individual respositories, but not the list of all of them with the security I'm using.
Here's my subversion file in my "debian" /etc/apache2/sites-available directory. I set up both digest authentication, ssl, and an authorization file. I can't tell what the "Satisfy Any" does.
# Uncomment this to enable the repository,
DAV svn
# Set this to the path to your repository
# SVNPath /var/lib/svn
SVNParentPath /home/subversion
SVNListParentPath on
AuthType Digest
AuthName "peters"
AuthDigestFile /etc/apache2/svn-admin/digest-password
SSLRequireSSL
# Uncomment the following line to enable Authz Authentication
AuthzSVNAccessFile /etc/apache2/auth-files/public-svn-authzfile
# SVNAutoVersioning On
# The following three lines allow anonymous read, but make
# committers authenticate themselves.
Satisfy Any
#<LimitExcept GET PROPFIND OPTIONS REPORT>
Require valid-user
#</LimitExcept>
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.