Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

haproxy_exporter: update 0.9.0->0.10.0 #338

Merged
merged 1 commit into from
Jul 15, 2019
Merged
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
2 changes: 1 addition & 1 deletion data/defaults.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ prometheus::haproxy_exporter::group: 'haproxy-exporter'
prometheus::haproxy_exporter::package_ensure: 'latest'
prometheus::haproxy_exporter::package_name: 'haproxy_exporter'
prometheus::haproxy_exporter::user: 'haproxy-user'
prometheus::haproxy_exporter::version: '0.9.0'
prometheus::haproxy_exporter::version: '0.10.0'
prometheus::nginx_vts_exporter::nginx_scrape_uri: 'http://localhost/status/format/json'
prometheus::nginx_vts_exporter::download_extension: 'tar.gz'
prometheus::nginx_vts_exporter::download_url_base: 'https://github.com/hnlq715/nginx-vts-exporter/releases'
Expand Down
33 changes: 33 additions & 0 deletions spec/acceptance/haproxy_exporter_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -53,4 +53,37 @@
it { is_expected.to be_listening.with('tcp6') }
end
end

describe 'haproxy_exporter update from 0.9.0 to 0.10.0' do
it 'is idempotent' do
pp = "class{'prometheus::haproxy_exporter': version => '0.9.0'}"
# Run it twice and test for idempotency
apply_manifest(pp, catch_failures: true)
apply_manifest(pp, catch_changes: true)
end

describe service('haproxy_exporter') do
it { is_expected.to be_running }
it { is_expected.to be_enabled }
end

describe port(9101) do
it { is_expected.to be_listening.with('tcp6') }
end
it 'is idempotent' do
pp = "class{'prometheus::haproxy_exporter': version => '0.10.0'}"
# Run it twice and test for idempotency
apply_manifest(pp, catch_failures: true)
apply_manifest(pp, catch_changes: true)
end

describe service('haproxy_exporter') do
it { is_expected.to be_running }
it { is_expected.to be_enabled }
end

describe port(9101) do
it { is_expected.to be_listening.with('tcp6') }
end
end
end