Skip to content
This repository was archived by the owner on Apr 16, 2018. It is now read-only.
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions manifests/params.pp
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,20 @@
# Icinga2 client settings
$checkplugin_libdir = '/usr/local/libexec/nagios'
}
'FreeBSD': {
$plugin_packages = [
'monitoring-plugins',
]
$mail_package = undef

#Settings for /etc/icinga2/:
$config_owner = 'icinga'
$config_group = 'icinga'
$config_mode = '0640'

# Icinga2 client settings
$checkplugin_libdir = '/usr/local/libexec/nagios'
}
#Fail if we're on any other OS:
default: { fail("${::operatingsystem} is not supported!") }
}
Expand Down
11 changes: 11 additions & 0 deletions spec/classes/icinga2_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -103,4 +103,15 @@
it { should contain_class('icinga2::params') }
end

context 'on FreeBSD' do
let :facts do
IcingaPuppet.variants['FreeBSD 10.2']
end

it { should compile }
it { should contain_class('icinga2') }
it { should contain_class('icinga2::params') }
it { should contain_file('/usr/local/etc/icinga2') }
end

end
8 changes: 8 additions & 0 deletions spec/variants.rb
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,14 @@ def self.variants
:path => '/dummy',
:nrpe_daemon_name => 'nrpe',
},
'FreeBSD 10.2' => {
:osfamily => 'FreeBSD',
:operatingsystem => 'FreeBSD',
:operatingsystemrelease => '10.2-RELEASE',
:operatingsystemmajrelease => '10',
:path => '/dummy',
#:nrpe_daemon_name => 'nrpe',
},
}
end
end