diff --git a/tripleoclient/tests/v1/undercloud/test_install_upgrade.py b/tripleoclient/tests/v1/undercloud/test_install_upgrade.py index 5332bf284..733fbb9d6 100644 --- a/tripleoclient/tests/v1/undercloud/test_install_upgrade.py +++ b/tripleoclient/tests/v1/undercloud/test_install_upgrade.py @@ -102,9 +102,7 @@ class TestUndercloudInstall(TestPluginV1): '/usr/share/openstack-tripleo-heat-templates/environments/' 'ssl/tls-endpoints-public-ip.yaml', '-e', '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-haproxy.yaml', '-e', - '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-keepalived.yaml', + 'services/undercloud-haproxy.yaml', # TODO(cjeanner) drop once we have proper oslo.privsep '--deployment-user', 'stack', '--output-dir=/home/stack', '--cleanup', @@ -163,8 +161,7 @@ class TestUndercloudInstall(TestPluginV1): '--public-virtual-ip', '192.168.24.2', '--control-virtual-ip', '192.168.24.3', '-e', '/usertht/environments/ssl/tls-endpoints-public-ip.yaml', '-e', - '/usertht/environments/services/undercloud-haproxy.yaml', '-e', - '/usertht/environments/services/undercloud-keepalived.yaml', + '/usertht/environments/services/undercloud-haproxy.yaml', # TODO(cjeanner) drop once we have proper oslo.privsep '--deployment-user', 'stack', '--output-dir=/foo', '--cleanup', '-e', @@ -328,9 +325,7 @@ class TestUndercloudInstall(TestPluginV1): '/usr/share/openstack-tripleo-heat-templates/environments/' 'ssl/tls-endpoints-public-ip.yaml', '-e', '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-haproxy.yaml', '-e', - '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-keepalived.yaml', + 'services/undercloud-haproxy.yaml', # TODO(cjeanner) drop once we have proper oslo.privsep '--deployment-user', 'stack', '--output-dir=/home/stack', @@ -394,9 +389,7 @@ class TestUndercloudInstall(TestPluginV1): '/usr/share/openstack-tripleo-heat-templates/environments/' 'ssl/tls-endpoints-public-ip.yaml', '-e', '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-haproxy.yaml', '-e', - '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-keepalived.yaml', + 'services/undercloud-haproxy.yaml', # TODO(cjeanner) drop once we have proper oslo.privsep '--deployment-user', 'stack', '--output-dir=/home/stack', '--cleanup', @@ -456,9 +449,7 @@ class TestUndercloudInstall(TestPluginV1): '/usr/share/openstack-tripleo-heat-templates/environments/' 'ssl/tls-endpoints-public-ip.yaml', '-e', '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-haproxy.yaml', '-e', - '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-keepalived.yaml', + 'services/undercloud-haproxy.yaml', # TODO(cjeanner) drop once we have proper oslo.privsep '--deployment-user', 'stack', '--output-dir=/home/stack', '--cleanup', @@ -519,9 +510,7 @@ class TestUndercloudInstall(TestPluginV1): '/usr/share/openstack-tripleo-heat-templates/environments/' 'ssl/tls-endpoints-public-ip.yaml', '-e', '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-haproxy.yaml', '-e', - '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-keepalived.yaml', + 'services/undercloud-haproxy.yaml', '--deployment-user', 'stack', '--output-dir=/home/stack', '--cleanup', '-e', '/home/stack/tripleo-config-generated-env-files/' @@ -664,9 +653,7 @@ class TestUndercloudUpgrade(TestPluginV1): '/usr/share/openstack-tripleo-heat-templates/environments/' 'ssl/tls-endpoints-public-ip.yaml', '-e', '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-haproxy.yaml', '-e', - '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-keepalived.yaml', + 'services/undercloud-haproxy.yaml', # TODO(cjeanner) drop once we have proper oslo.privsep '--deployment-user', 'stack', '--output-dir=/home/stack', '--cleanup', @@ -730,9 +717,7 @@ class TestUndercloudUpgrade(TestPluginV1): '/usr/share/openstack-tripleo-heat-templates/environments/' 'ssl/tls-endpoints-public-ip.yaml', '-e', '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-haproxy.yaml', '-e', - '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-keepalived.yaml', + 'services/undercloud-haproxy.yaml', '--deployment-user', 'stack', '--output-dir=/home/stack', '--cleanup', '-e', '/home/stack/tripleo-config-generated-env-files/' @@ -795,9 +780,7 @@ class TestUndercloudUpgrade(TestPluginV1): '/usr/share/openstack-tripleo-heat-templates/environments/' 'ssl/tls-endpoints-public-ip.yaml', '-e', '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-haproxy.yaml', '-e', - '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-keepalived.yaml', + 'services/undercloud-haproxy.yaml', # TODO(cjeanner) drop once we have proper oslo.privsep '--deployment-user', 'stack', '--output-dir=/home/stack', '--cleanup', @@ -858,9 +841,7 @@ class TestUndercloudUpgrade(TestPluginV1): '/usr/share/openstack-tripleo-heat-templates/environments/' 'ssl/tls-endpoints-public-ip.yaml', '-e', '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-haproxy.yaml', '-e', - '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-keepalived.yaml', + 'services/undercloud-haproxy.yaml', # TODO(cjeanner) drop once we have proper oslo.privsep '--deployment-user', 'stack', '--output-dir=/home/stack', '--cleanup', @@ -927,9 +908,7 @@ class TestUndercloudUpgrade(TestPluginV1): '/usr/share/openstack-tripleo-heat-templates/environments/' 'ssl/tls-endpoints-public-ip.yaml', '-e', '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-haproxy.yaml', '-e', - '/usr/share/openstack-tripleo-heat-templates/environments/' - 'services/undercloud-keepalived.yaml', + 'services/undercloud-haproxy.yaml', '--deployment-user', 'stack', '--output-dir=/home/stack', '--cleanup', '-e', '/home/stack/tripleo-config-generated-env-files/' diff --git a/tripleoclient/v1/undercloud_config.py b/tripleoclient/v1/undercloud_config.py index f2759f0bc..c61cb4a8a 100644 --- a/tripleoclient/v1/undercloud_config.py +++ b/tripleoclient/v1/undercloud_config.py @@ -721,41 +721,17 @@ def prepare_undercloud_deploy(upgrade=False, no_validations=True, admin_ip = netaddr.IPAddress(admin_host) deploy_args += ['--control-virtual-ip', admin_host] - if CONF.get('net_config_override', None): - if (admin_ip not in local_net.cidr): - LOG.warning('You may need to specify a custom ' - 'ControlVirtualInterface in a custom env file to ' - 'correctly assign the ip address to an interface ' - 'for undercloud_admin_host. By default it will be ' - 'set to br-ctlplane.') - if (public_ip not in local_net.cidr): - LOG.warning('You may need to specify a custom ' - 'PublicVirtualInterface in a custom env file to ' - 'correctly assign the ip address to an interface ' - 'for undercloud_public_host. By default it will be' - ' set to br-ctlplane.') - else: + if not CONF.get('net_config_override', None): if (admin_ip not in local_net.cidr or public_ip not in local_net.cidr): LOG.warning('undercloud_admin_host or undercloud_public_host ' 'is not in the same cidr as local_ip.') - # Define the *VirtualInterfaces for keepalived. These are used when - # configuring the undercloud_*_host addresses. If these adddesses are - # not in the default cidr for the ctlplane, it will not be defined - # and leads to general sadness during the deployment. Our default - # net_config uses br-ctlplane. See rhbz#1737150 - env_data['ControlVirtualInterface'] = 'br-ctlplane' - env_data['PublicVirtualInterface'] = 'br-ctlplane' - deploy_args += [ '-e', endpoint_environment, '-e', os.path.join( tht_templates, - 'environments/services/undercloud-haproxy.yaml'), - '-e', os.path.join( - tht_templates, - 'environments/services/undercloud-keepalived.yaml')] + 'environments/services/undercloud-haproxy.yaml')] u = CONF.get('deployment_user') or utils.get_deployment_user() env_data['DeploymentUser'] = u