Disable telemetry if it's not enabled

The disable-telemetry.yaml environment is used to disable all the
telemetry services and to disable the notification drivers. Since we
didn't have this by default, notifications were still being sent to
the undercloud rabbitmq and never consumed.

Conflicts:
	tripleoclient/tests/v1/undercloud/test_undercloud.py

Change-Id: I53eab2c41c80f5dafff9824bf3086e1d9a369e22
Closes-Bug: #1838828
(cherry picked from commit 0faa33a6b0)
This commit is contained in:
Alex Schultz 2019-08-05 09:49:57 -06:00
parent 376d874403
commit 2e0b581f72
2 changed files with 25 additions and 0 deletions

View File

@ -88,6 +88,8 @@ class TestUndercloudInstall(TestPluginV1):
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/zaqar-swift-backend.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'disable-telemetry.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tripleo-ui.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tempest.yaml', '-e',
@ -161,6 +163,8 @@ class TestUndercloudInstall(TestPluginV1):
'/usertht/environments/services/ironic-inspector.yaml', '-e',
'/usertht/environments/services/mistral.yaml', '-e',
'/usertht/environments/services/zaqar-swift-backend.yaml', '-e',
'/usertht/environments/'
'disable-telemetry.yaml', '-e',
'/usertht/environments/services/tripleo-ui.yaml', '-e',
'/usertht/environments/services/tempest.yaml', '-e',
'/usertht/environments/public-tls-undercloud.yaml',
@ -323,6 +327,8 @@ class TestUndercloudInstall(TestPluginV1):
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/zaqar-swift-backend.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'disable-telemetry.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tripleo-ui.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tempest.yaml', '-e',
@ -391,6 +397,8 @@ class TestUndercloudInstall(TestPluginV1):
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/zaqar-swift-backend.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'disable-telemetry.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tripleo-ui.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tempest.yaml', '-e',
@ -455,6 +463,8 @@ class TestUndercloudInstall(TestPluginV1):
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/zaqar-swift-backend.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'disable-telemetry.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tripleo-ui.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tempest.yaml', '-e',
@ -516,6 +526,8 @@ class TestUndercloudInstall(TestPluginV1):
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/zaqar-swift-backend.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'disable-telemetry.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tripleo-ui.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tempest.yaml', '-e',
@ -596,6 +608,8 @@ class TestUndercloudUpgrade(TestPluginV1):
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/zaqar-swift-backend.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'disable-telemetry.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tripleo-ui.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tempest.yaml', '-e',
@ -683,6 +697,8 @@ class TestUndercloudUpgrade(TestPluginV1):
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/zaqar-swift-backend.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'disable-telemetry.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tripleo-ui.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tempest.yaml', '-e',
@ -746,6 +762,8 @@ class TestUndercloudUpgrade(TestPluginV1):
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/zaqar-swift-backend.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'disable-telemetry.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tripleo-ui.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tempest.yaml', '-e',
@ -809,6 +827,8 @@ class TestUndercloudUpgrade(TestPluginV1):
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/zaqar-swift-backend.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'disable-telemetry.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tripleo-ui.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tempest.yaml', '-e',
@ -876,6 +896,8 @@ class TestUndercloudUpgrade(TestPluginV1):
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/zaqar-swift-backend.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'disable-telemetry.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tripleo-ui.yaml', '-e',
'/usr/share/openstack-tripleo-heat-templates/environments/'
'services/tempest.yaml', '-e',

View File

@ -413,6 +413,9 @@ def prepare_undercloud_deploy(upgrade=False, no_validations=False,
if CONF.get('enable_telemetry'):
for env_file in TELEMETRY_DOCKER_ENV_YAML:
deploy_args += ['-e', os.path.join(tht_templates, env_file)]
else:
deploy_args += ['-e', os.path.join(
tht_templates, "environments/disable-telemetry.yaml")]
if CONF.get('enable_ui'):
deploy_args += ['-e', os.path.join(