Add integration_enable option to beaker test

Change-Id: If3a1c1299de725c23e2586453c9ab85e9db988b8
This commit is contained in:
ZhongShengping 2018-03-20 13:44:21 +08:00
parent d568432e1f
commit 34a0a5c980

View File

@ -4,8 +4,13 @@
# (optional) Enable polling for the compute namespace
# Default to true.
#
# [*integration_enable*]
# (optional) Boolean to run integration tests.
# Defaults to true.
#
class openstack_integration::ceilometer (
$compute_namespace = true,
$integration_enable = true,
){
include ::openstack_integration::config
@ -54,10 +59,11 @@ class openstack_integration::ceilometer (
configure_endpoint => false,
}
if $integration_enable {
# Ensure Gnocchi and creads are ready before running ceilometer-upgrade
# We use Gnocchi/Panko instead of local database, db::sync is required to populate
# gnocchi resource types.
include ::ceilometer::db::sync
# Ensure Gnocchi and creads are ready before running ceilometer-upgrade
Service['httpd'] -> Exec['ceilometer-upgrade']
Class['ceilometer::agent::auth'] -> Exec['ceilometer-upgrade']
Class['ceilometer::keystone::auth'] -> Exec['ceilometer-upgrade']
@ -81,6 +87,16 @@ class openstack_integration::ceilometer (
# tests are too long to pass in less than 1 hour.
polling_interval => 60,
}
} else {
# NOTE(tobasco): When running the beaker tests we need to exclude the
# gnocchi resource types since the acceptance test does not setup gnocchi itself.
class { '::ceilometer::db::sync':
extra_params => '--skip-gnocchi-resource-types',
}
class { '::ceilometer::agent::notification': }
}
class { '::ceilometer::expirer': }
class { '::ceilometer::agent::auth':
auth_password => 'a_big_secret',
auth_url => $::openstack_integration::config::keystone_auth_uri,