[distcc] distccd, --allow, and /etc/init.d
Hamish Greig
hgreig at bigpond.net.au
Wed Jun 15 22:40:42 GMT 2005
On Thu, 16 Jun 2005 07:42, Daniel Kegel wrote:
> The --allow option is now mandatory for distcc's daemon mode.
> This is a good thing; I hate letting somebody else's
> Aunt Tilly have the ability to run processes on my box :-)
>
> But it presents a challenge for those packaging
> distccd up as an rpm. The rpm comes with an /etc/init.d script
> to start up daemon mode. Now, I could require the person
> installing the rpm to edit that script and put in the
> right argument for --allow, but that's not going to go
> over well for my users.
>
> I'd love to do some sed hackery on the output of ifconfig
> to come up with a value of --allow that allows connections
> from any network the server is directly connected to,
> but that's not always enough in my case.
>
> I think what I'm going to do is have the init script read
> /etc/distccd.allow to get the list of networks to pass to --allow.
> The format will be simple:
> ipadr/size
> ipadr/size
> ...
> so it's easy for networks ops people (who would not enjoy
> editing /etc/init.d/distccd) to maintain.
>
> Comments? Anyone else done this before?
> __
I actually use similar, the initscript sources /etc/sysconfig/distccd
which sets these up as follows.
+++++++++++++++++++++++
# choose the range of IP addresses allowed to connect to the server
CLIENT_RANGE=10.0.0.0/1-15
# choose the log level, error by default
LEVEL=error
+++++++++++++++++++++++
this makes it easy to change the log level without delving into the init
script also.
I use simpleinit-msb so my initscript won't be that helpful, but the actual
command is
/usr/bin/distccd --daemon --allow="$CLIENT_RANGE" --log-level "$LEVEL" \
--user distcc -P /var/run/distccd.pid
Hamish
More information about the distcc
mailing list