I’ve just uploaded my first puppet module to the forge,
optiz0r-sabayon, which improves support for the Sabayon Linux distribution in puppet.
This does the following things:
- Overrides the
operatingsystem fact for Sabayon hosts
- Adds a provider for
entropy package manager, and sets this as the default for Sabayon
- Adds a shim
service provider, that marks
systemd as the default for Sabayon hosts
- Adds an
enman_repo type which manages installation of Sabayon Community Repositories onto a Sabayon host
entropy_unmask types, which manage package masks and unmasks
I’ll add more features as and when I need them. In the meantime, pull requests welcome!
Does ZFS work on Sabayon? Yes, very nicely 🙂 Here’s how:
I like puppet and I like Sabayon but out of the box they don’t play nicely together. Sabayon is a Gentoo derivative and looks to puppet like a Gentoo system which causes it to use the Gentoo providers for package and service resources. Unlike a stock gentoo install, Sabayon hosts use systemd and a binary package manager (entropy). While entropy is compatible with portage I don’t want to compile things from source on my Sabayon boxes.
I’ve put together a a puppet module (https://github.com/optiz0r/puppet-sabayon/) which adds support for Sabayon by doing the following things:
- Overriding the operatingsystem fact to distinguish between Gentoo and Sabayon (osfamily still describes it as Gentoo)
- Adding an
init fact which reports whether systemd is running
- Subclassing the Systemd service provider to make it the default when the
init fact reports systemd is in use
- Adding a
has_entropy fact that checks whether equo is available
- Adding an Entropy package provider that’s the default for systems where
has_entropy is true (and when
operatingsystem is Sabayon, but that’s mostly a hack to override the portage default)
To use it, just add the module to your environment, and
pluignsync will do all the hard work.
Known issue: The entropy provider doesn’t behave well when it tries to install a package which has a new license not already included in [startCodet]license.accept. Equo will present a prompt to accept the license in this case, which fails since there’s no stdin to read the answer from. This causes the prompt to be reprinted in a tight loop while puppet captures the output and fills up /tmp. I’ve got a bug report to change the equo behaviour. Once this issue is resolved I’ll package up the module properly and submit it to the forge, but in the meantime it’s around if people might find it useful.