2019-04-24 18:18:10 +02:00
|
|
|
control 'Prometheus configuration' do
|
|
|
|
title 'should match desired lines'
|
|
|
|
|
|
|
|
describe file('/etc/prometheus/prometheus.yml') do
|
|
|
|
it { should be_file }
|
2019-06-23 18:18:40 +02:00
|
|
|
it { should be_owned_by 'prometheus' }
|
|
|
|
it { should be_grouped_into 'prometheus' }
|
2019-04-24 18:18:10 +02:00
|
|
|
its('mode') { should cmp '0644' }
|
|
|
|
its('content') { should include 'File managed by Salt' }
|
2019-06-16 02:33:24 +02:00
|
|
|
its('content') { should include 'Your changes may be overwritten.' }
|
2019-04-24 18:18:10 +02:00
|
|
|
its('content') { should include 'global:' }
|
|
|
|
its('content') { should include 'alerting:' }
|
|
|
|
end
|
2019-10-04 01:20:16 +02:00
|
|
|
|
|
|
|
describe file('/opt/prometheus/textfile_collectors/ipmitool') do
|
|
|
|
it { should be_file }
|
|
|
|
it { should be_owned_by 'root' }
|
|
|
|
its('mode') { should cmp '0755' }
|
|
|
|
end
|
2019-04-24 18:18:10 +02:00
|
|
|
end
|