User to run ${command} as,
using su(1) does not work for all reasons
Dag-Erling Smørgrav
des at des.no
Mon Nov 3 04:04:35 PST 2008
Volker Theile <votdev at gmx.de> writes:
> i came across the following problem while trying to run
> transmission-daemon using user 'transmission'. When i modify the
> transmission rc-script to use another user than root for execution i
> added:
>
> transmission_user=${transmission_user:-"transmission"}
>
> Because there is not done a full login the transmission daemon tries
> to create its config dir in /root/.config/transmission_daemon which
> fails due missing permissions.
There's another, bigger issue with _user and _group. A daemon that
needs to, say, open a privileged port can't use _user and _group,
because it will start as that user / group instead of starting as root
and then dropping privileges on its own. This affects named in base and
varnishd (and probably others) in ports. There should be a way to tell
rc.subr that the daemon will handle _user and _group itself.
DES
--
Dag-Erling Smørgrav - des at des.no
More information about the freebsd-rc
mailing list