Automatically running SVNserve on boot

Whether you are using Linux on the desktop or as a server, it's still good that you're using Linux. Linux related questions go here.

Moderator: General Moderators

Post Reply
alex.barylski
DevNet Evangelist
Posts: 6267
Joined: Tue Dec 21, 2004 5:00 pm
Location: Winnipeg

Automatically running SVNserve on boot

Post by alex.barylski »

EDIT | Running as daemon not inetd

I have googled and it seems the only solution under *nix is to manually add the entry to the /etc/rc.local???

The only problem is, SVN suggests running svnserve as a user that wholly owns the repo's -- makes sense.

I have a user and group SVN but running the daemon from /etc/rc.local -- wouldn't this run SVN as root? How do I run SVNserve at bootup under the user SVN???
waylon999
Forum Commoner
Posts: 26
Joined: Mon Mar 23, 2009 5:29 pm

Re: Automatically running SVNserve on boot

Post by waylon999 »

You can write a script that switches user and then calls the daemon you want to run

Code: Select all

sudo -u SVN /location/of/script
Something like that should run the script as a different user. Which linux are you using? I am used to Ubuntu, so I would write a bash script and put it in /etc/init.d.
wispa
Forum Newbie
Posts: 5
Joined: Sun May 10, 2009 7:41 am

Re: Automatically running SVNserve on boot

Post by wispa »

could you run it as a cron job using the @reboot command?

Personally not tried it myself but possibly something to look into
Post Reply