Skip to content

Commit

Permalink
Merge pull request #338 from bastelfreak/updates6
Browse files Browse the repository at this point in the history
haproxy_exporter: update 0.9.0->0.10.0
  • Loading branch information
bastelfreak committed Jul 15, 2019
2 parents b6130da + 1c23327 commit a2d9566
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 1 deletion.
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

0 comments on commit a2d9566

Please sign in to comment.