Skip to content

Commit

Permalink
Fix failure when setting faillock_log_dir (#123)
Browse files Browse the repository at this point in the history
This patch fixes a bug that failed when setting faillock_log_dir

Fixes #122

Co-authored-by: op-ct <[email protected]>
  • Loading branch information
michael-riddle and op-ct authored Apr 14, 2022
1 parent bb96087 commit 4e94a1c
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 2 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
* Wed Apr 13 2022 Mike Riddle <[email protected]> - 6.11.1
- Fix bug that failed when setting faillock_log_dir parameter

* Mon Mar 28 2022 Mike Riddle <[email protected]> - 6.11.0
- Add dictcheck parameter to pwquality
- Add faillock_log_file parameter
Expand Down
2 changes: 1 addition & 1 deletion manifests/config.pp
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@
}

if ($pam::faillock_log_dir) {
file { '$pam::faillock_log_dir':
file { $pam::faillock_log_dir:
ensure => 'dir',
owner => 'root',
group => 'root',
Expand Down
2 changes: 1 addition & 1 deletion metadata.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "simp-pam",
"version": "6.11.0",
"version": "6.11.1",
"author": "SIMP Team",
"summary": "A SIMP puppet module for managing pam",
"license": "Apache-2.0",
Expand Down
5 changes: 5 additions & 0 deletions spec/classes/config_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -292,6 +292,11 @@
}
end

context 'with faillock_log_dir set' do
let(:params){{ :faillock_log_dir => '/var/log/faillock' }}
it { is_expected.to contain_file('/var/log/faillock') }
end

context 'no warn_if_unknown = false' do
let(:params){{ :warn_if_unknown => false }}
it { is_expected.to contain_file('/etc/pam.d/other').with_content(<<~EOM
Expand Down

0 comments on commit 4e94a1c

Please sign in to comment.