Added FreeBSD support
This commit is contained in:
parent
7f59387532
commit
658c6520a0
3
.vscode/settings.json
vendored
Normal file
3
.vscode/settings.json
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
{
|
||||
"puppet.editorService.puppet.version": "7.23.0"
|
||||
}
|
@ -109,7 +109,7 @@ class nslcd
|
||||
Boolean $service_manage = true,
|
||||
String[1] $uid = 'nslcd',
|
||||
String[1] $gid = $nslcd::params::gid,
|
||||
Stdlib::Unixpath $config = '/etc/nslcd.conf',
|
||||
Stdlib::Unixpath $config = $nslcd::params::config,
|
||||
String[1] $config_user = 'root',
|
||||
String[1] $config_group = $nslcd::params::config_group,
|
||||
Stdlib::Filemode $config_mode = $nslcd::params::config_mode,
|
||||
|
@ -2,26 +2,30 @@
|
||||
#
|
||||
# Sets the default parameters for the nslcd class.
|
||||
#
|
||||
class nslcd::params
|
||||
{
|
||||
case $::osfamily
|
||||
{
|
||||
'Debian':
|
||||
{
|
||||
class nslcd::params {
|
||||
case $::osfamily {
|
||||
'Debian': {
|
||||
$package_name = 'nslcd'
|
||||
$gid = 'nslcd'
|
||||
$config = '/etc/nslcd.conf'
|
||||
$config_group = 'nslcd'
|
||||
$config_mode = '0640'
|
||||
}
|
||||
'RedHat':
|
||||
{
|
||||
'RedHat': {
|
||||
$package_name = 'nss-pam-ldapd'
|
||||
$gid = 'ldap'
|
||||
$config = '/etc/nslcd.conf'
|
||||
$config_group = 'root'
|
||||
$config_mode = '0600'
|
||||
}
|
||||
default:
|
||||
{
|
||||
'FreeBSD': {
|
||||
$package_name = 'nss-pam-ldapd'
|
||||
$gid = 'nslcd'
|
||||
$config = '/usr/local/etc/nslcd.conf'
|
||||
$config_group = 'wheel'
|
||||
$config_mode = '0600'
|
||||
}
|
||||
default: {
|
||||
fail("The ${module_name} module is not supported on an ${::osfamily} based system.")
|
||||
}
|
||||
}
|
||||
|
@ -2,16 +2,12 @@
|
||||
#
|
||||
# Manages the nslcd service.
|
||||
#
|
||||
class nslcd::service inherits nslcd
|
||||
{
|
||||
if $nslcd::service_manage
|
||||
{
|
||||
service
|
||||
{
|
||||
'nslcd':
|
||||
ensure => $nslcd::service_ensure,
|
||||
enable => $nslcd::service_enable,
|
||||
name => $nslcd::service_name,
|
||||
class nslcd::service inherits nslcd {
|
||||
if $nslcd::service_manage {
|
||||
service { 'nslcd':
|
||||
ensure => $nslcd::service_ensure,
|
||||
enable => $nslcd::service_enable,
|
||||
name => $nslcd::service_name,
|
||||
}
|
||||
}
|
||||
}
|
@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "geekix-nslcd",
|
||||
"name": "ascendings-nslcd",
|
||||
"version": "0.4.3",
|
||||
"author": "geekix",
|
||||
"author": "ascendings",
|
||||
"summary": "Installs and configures nslcd.",
|
||||
"license": "Apache-2.0",
|
||||
"source": "https://github.com/geekix/puppet-nslcd",
|
||||
"project_page": "https://github.com/geekix/puppet-nslcd",
|
||||
"issues_url": "https://github.com/geekix/puppet-nslcd/issues",
|
||||
"source": "https://git.metaunix.net/Metaunix/puppet-nslcd",
|
||||
"project_page": "https://git.metaunix.net/Metaunix/puppet-nslcd",
|
||||
"issues_url": "https://git.metaunix.net/Metaunix/puppet-nslcd/issues",
|
||||
"dependencies": [
|
||||
{
|
||||
"name": "puppetlabs-stdlib",
|
||||
@ -38,6 +38,9 @@
|
||||
"7",
|
||||
"8"
|
||||
]
|
||||
},
|
||||
{
|
||||
"operatingsystem": "FreeBSD"
|
||||
}
|
||||
],
|
||||
"requirements": [
|
||||
|
Loading…
Reference in New Issue
Block a user