10 Commits

Author SHA1 Message Date
20144b511d Update config.yml 2021-11-08 12:13:43 +01:00
e9b327cc0c Update config.yml 2021-11-08 11:55:14 +01:00
a72f539c23 Update config.yml 2021-11-08 11:21:00 +01:00
c8fa6599ff Update config.yml 2021-11-08 09:36:52 +01:00
eba85e08df Update init.pp 2021-11-08 09:35:14 +01:00
6d478b124c Update config.yml 2021-11-08 09:34:00 +01:00
c06708dc91 Update config.yml 2021-11-08 09:33:40 +01:00
e24a9aa89a Update config.yml 2021-11-08 09:29:24 +01:00
bd5fbd4cc6 Update config.yml 2021-11-07 11:52:46 +01:00
418a817b70 Add .circleci/config.yml 2021-11-06 17:11:44 +01:00
7 changed files with 61 additions and 50 deletions

30
.circleci/config.yml Normal file
View File

@ -0,0 +1,30 @@
version: 2.1
orbs:
ruby: circleci/ruby@1.1.0
node: circleci/node@2
jobs:
verif:
docker:
- image: cimg/ruby:2.7-node
steps:
- checkout
- run :
name: prerequisites
command: bundle install
- run:
name: verif_lint
command: bundle exec rake validate lint
- run:
name: verif_parser
command: puppet parser validate manifests/init.pp
- run:
name: woot
command: bundle exec rake spec
workflows:
version: 2
verif:
jobs:
- verif

View File

@ -1,3 +0,0 @@
{
"puppet.editorService.puppet.version": "7.23.0"
}

View File

@ -2,13 +2,7 @@
All notable changes to this project will be documented in this file. All notable changes to this project will be documented in this file.
## 0.4.3 (2021-11-07) ## 0.4.2 (2021-05-11)
### Changed
- Add support for RedHat RHEL in the metadata
## 0.4.2 (2021-11-05)
### Addition ### Addition

View File

@ -109,7 +109,7 @@ class nslcd
Boolean $service_manage = true, Boolean $service_manage = true,
String[1] $uid = 'nslcd', String[1] $uid = 'nslcd',
String[1] $gid = $nslcd::params::gid, String[1] $gid = $nslcd::params::gid,
Stdlib::Unixpath $config = $nslcd::params::config, Stdlib::Unixpath $config = '/etc/nslcd.conf',
String[1] $config_user = 'root', String[1] $config_user = 'root',
String[1] $config_group = $nslcd::params::config_group, String[1] $config_group = $nslcd::params::config_group,
Stdlib::Filemode $config_mode = $nslcd::params::config_mode, Stdlib::Filemode $config_mode = $nslcd::params::config_mode,
@ -137,7 +137,7 @@ inherits nslcd::params
contain nslcd::install contain nslcd::install
contain nslcd::config contain nslcd::config
contain nslcd::service contain nslcd::service
Class['nslcd::install'] Class['nslcd::install']
-> Class['nslcd::config'] -> Class['nslcd::config']
~> Class['nslcd::service'] ~> Class['nslcd::service']

View File

@ -2,31 +2,27 @@
# #
# Sets the default parameters for the nslcd class. # Sets the default parameters for the nslcd class.
# #
class nslcd::params { class nslcd::params
case $::osfamily { {
'Debian': { case $::osfamily
{
'Debian':
{
$package_name = 'nslcd' $package_name = 'nslcd'
$gid = 'nslcd' $gid = 'nslcd'
$config = '/etc/nslcd.conf'
$config_group = 'nslcd' $config_group = 'nslcd'
$config_mode = '0640' $config_mode = '0640'
} }
'RedHat': { 'RedHat':
{
$package_name = 'nss-pam-ldapd' $package_name = 'nss-pam-ldapd'
$gid = 'ldap' $gid = 'ldap'
$config = '/etc/nslcd.conf'
$config_group = 'root' $config_group = 'root'
$config_mode = '0600' $config_mode = '0600'
} }
'FreeBSD': { default:
$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.") fail("The ${module_name} module is not supported on an ${::osfamily} based system.")
} }
} }
} }

View File

@ -2,12 +2,16 @@
# #
# Manages the nslcd service. # Manages the nslcd service.
# #
class nslcd::service inherits nslcd { class nslcd::service inherits nslcd
if $nslcd::service_manage { {
service { 'nslcd': if $nslcd::service_manage
ensure => $nslcd::service_ensure, {
enable => $nslcd::service_enable, service
name => $nslcd::service_name, {
'nslcd':
ensure => $nslcd::service_ensure,
enable => $nslcd::service_enable,
name => $nslcd::service_name,
} }
} }
} }

View File

@ -1,12 +1,12 @@
{ {
"name": "ascendings-nslcd", "name": "geekix-nslcd",
"version": "0.5.0", "version": "0.4.2",
"author": "ascendings", "author": "geekix",
"summary": "Installs and configures nslcd.", "summary": "Installs and configures nslcd.",
"license": "Apache-2.0", "license": "Apache-2.0",
"source": "https://git.metaunix.net/Metaunix/puppet-nslcd", "source": "https://github.com/geekix/puppet-nslcd",
"project_page": "https://git.metaunix.net/Metaunix/puppet-nslcd", "project_page": "https://github.com/geekix/puppet-nslcd",
"issues_url": "https://git.metaunix.net/Metaunix/puppet-nslcd/issues", "issues_url": "https://github.com/geekix/puppet-nslcd/issues",
"dependencies": [ "dependencies": [
{ {
"name": "puppetlabs-stdlib", "name": "puppetlabs-stdlib",
@ -31,16 +31,6 @@
"18.04", "18.04",
"20.04" "20.04"
] ]
},
{
"operatingsystem": "RedHat RHEL",
"operatingsystemrelease": [
"7",
"8"
]
},
{
"operatingsystem": "FreeBSD"
} }
], ],
"requirements": [ "requirements": [