[talk] classifying BSD init

Brian Coca briancoca+nycbug at gmail.com
Tue Sep 1 18:24:48 EDT 2015


First of all, thanks for all the feedback,

It seems clear that codewise I need to keep the current distinction
that makes the systems specific to each BSD. But part of my
consideration of making this a single vs multiple plugins is that one
of the project goals is to simplify administration. The current
service module give a very generic and simple interface:

#  make sure sshd is started and will start at boot
- service: name=sshd state=started enabled=yes

In the case of systemd and upstart we have plenty of 'special'
requirements or very specific calls that need to be added, like
systemd's daemon-reload,  reenable, etc.  Which is my main reason to
split the service plugin. But in the case of sysvinit and the BSD
inits most of the functionality seems to still be uniform (even if the
implementations are not).

Can I get away with keeping sysvinit, openrc and the BSD inits in one
module? the code would still be a bit complex and handle the different
implementations, but I expect that they all have the same simple
interface. Or am I missing some functionality that would change the
interface for the BSDs? It would be nice that the most work to port a
configuration from one system to the other would be replacing the
service name.

Thanks in advance,

PS. I'm already adding DragonFly and Bitrig to proper detection and
equating them mostly to FreeBSD and OpenBSD respectively.
-----------
Brian Coca



More information about the talk mailing list