Properly supporting devfs(8) rules in rc-scripts

Kian Mohageri kian.mohageri at gmail.com
Sun Sep 9 20:26:01 PDT 2007


I've set up isc-dhcpd to run chroot(2)ed, and I noticed that the
port's rc-script does not currently support devfs rulesets (so, by default,
none of the device nodes are hidden within the chroot environment).

Attached is a diff to introduce a variable, dhcpd_devfs_ruleset, to be
applied within the chroot environment so as to hide all unnecessary
nodes.

However, I am not sure if this is the proper way to do this, and I had
a few questions for more experienced users.  Hopefully this is the
right place, rather than freebsd-rc at ...

 - Is it incorrect to use devfs_domount (from rc.subr)?  I don't see
it being used anywhere else other than /etc/rc.d/named and I'm
guessing it may be new and unavailable on older hosts.

 - Would it be better to leave out the variable and just hide
everything that isn't needed?

Suggestions would be greatly appreciated.

-Kian
-------------- next part --------------
A non-text attachment was scrubbed...
Name: isc-dhcpd.in.diff
Type: application/octet-stream
Size: 989 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-ports/attachments/20070910/2b768ee0/isc-dhcpd.in.obj


More information about the freebsd-ports mailing list