On Wed, 06 Feb 2008 17:09:50 +0000
Alex Zbyslaw <[EMAIL PROTECTED]> wrote:
> I personally much prefer scripts in rc.d because it's much easier to
> migrate than crontabs, and if I never use a crontab I always know
> where to look.
> It looks to me like you shouldn't be starting the demon as user api -
> startups scripts should always be started as root. If the demon or
> whatever is supposed to run as api not root, then perhaps your script
> should say e.g.
> su api -c the-path-to-the-demon-or-whatever
> root can su to whoever without a password, and api can su to api
> without a password, and everyone else gets prompted.
It's actually built into /etc/rc.subr, the subversion server script is
a simple example of starting a daemon with a different user:
$ grep -v "^#" /usr/local/etc/rc.d/svnserve
firstname.lastname@example.org mailing list
To unsubscribe, send any mail to "[EMAIL PROTECTED]"