New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rebase pdxcat/xinetd against new upstream #15
Conversation
@@ -10,18 +10,37 @@ | |||
# } | |||
# | |||
class xinetd { | |||
include xinetd::params |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One comment is that the usual pattern is to use inherits
here so the rest of the module can reference $xinetd::package_name
(etc.) instead of $xinetd::params::package_name
and parameters can be added to the base class without editing the code elsewhere in the module.
The params class uses facts to set tailored filenames and paths for the node. This is desireable in order to support multiple operating systems.
Not all operating systems store their default xinetd configuration file in /etc/xinetd.conf. Converting from a flat file to a template in order to support those operating systems.
Make sure xinetd.d exists (not all OS packages automatically create such a file). Also rework init.pp order.
Add a bunch of extra xinetd::service parameters. Refactor a bit. Options that default to undef are not given a corresponding line in the xinetd service file, leaving their value to the xinetd default. Modified options: - bind = '0.0.0.0' + bind = undef New options: + access_times = undef + ensure = present + groups = 'yes' + log_on_failure = undef + log_type = undef + no_access = undef + only_from = undef + service_name = $title + xtype = undef
Previously, the file resource defaults in init.pp specified Package[$xinetd_service] as a dependency. This has some not-so-subtle problems. It has been fixed to use Package[$xinetd_package] as originally intended.
Whatever puppet is doing to restart the xinetd service, it's not working. Possibly puppet is issuing a "reload" command. Setting hasrestart to false will cause puppet to issue a stop command followed by a start command, which *does* do the right thing.
- Fix rebase errors
$confdir = $xinetd::params::xinetd_confdir, | ||
$conffile = $xinetd::params::xinetd_conffile, | ||
$package = $xinetd::params::xinetd_package, | ||
$service = $xinetd::params::xinetd_service |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you make these service_name
and package_name
instead of service
and package
? It makes it a lot easier to grep through the module :)
Also, the xinetd_*
variables in xinetd::params
should probably match these names unless you have a reason otherwise.
- refactor xinetd class to be parameterized - rename $real_wait to $_wait to indicate it was munged - use validate_re function to verify tcp|udp - rename $xinetd_* to * - remove duplicate include xinetd - refactor template not to use scope.lookupvar - fix failing spec tests - add dependency on stdlib - add failure on unsupported osfamiles
Rebase pdxcat/xinetd against new upstream
No description provided.