mirror of
https://github.com/dj-wasabi/ansible-telegraf.git
synced 2025-07-17 08:46:37 +00:00
28 lines
651 B
Ruby
28 lines
651 B
Ruby
require 'serverspec'
|
|
require 'spec_helper'
|
|
|
|
describe 'Telegraf Packages' do
|
|
describe package('telegraf') do
|
|
it { should be_installed }
|
|
end
|
|
end
|
|
|
|
|
|
describe 'Telegraf Services' do
|
|
describe service('telegraf') do
|
|
it { should be_enabled }
|
|
end
|
|
end
|
|
|
|
describe 'Telegraf Configuration' do
|
|
describe file('/etc/telegraf/telegraf.conf') do
|
|
it { should be_file}
|
|
it { should be_owned_by 'root'}
|
|
it { should be_grouped_into 'root'}
|
|
|
|
it { should contain "[[inputs.cpu]]" }
|
|
it { should contain "[[inputs.mem]]" }
|
|
it { should contain "urls = [\"http://localhost:8086\"]" }
|
|
end
|
|
end
|