[1chb1n,r=corey.bryant] Update amulet relation tests to account for recent name changes
This commit is contained in:
commit
961048658a
@ -808,6 +808,19 @@ class NeutronContext(OSContextGenerator):
|
|||||||
|
|
||||||
return ovs_ctxt
|
return ovs_ctxt
|
||||||
|
|
||||||
|
def nuage_ctxt(self):
|
||||||
|
driver = neutron_plugin_attribute(self.plugin, 'driver',
|
||||||
|
self.network_manager)
|
||||||
|
config = neutron_plugin_attribute(self.plugin, 'config',
|
||||||
|
self.network_manager)
|
||||||
|
nuage_ctxt = {'core_plugin': driver,
|
||||||
|
'neutron_plugin': 'vsp',
|
||||||
|
'neutron_security_groups': self.neutron_security_groups,
|
||||||
|
'local_ip': unit_private_ip(),
|
||||||
|
'config': config}
|
||||||
|
|
||||||
|
return nuage_ctxt
|
||||||
|
|
||||||
def nvp_ctxt(self):
|
def nvp_ctxt(self):
|
||||||
driver = neutron_plugin_attribute(self.plugin, 'driver',
|
driver = neutron_plugin_attribute(self.plugin, 'driver',
|
||||||
self.network_manager)
|
self.network_manager)
|
||||||
@ -891,6 +904,8 @@ class NeutronContext(OSContextGenerator):
|
|||||||
ctxt.update(self.n1kv_ctxt())
|
ctxt.update(self.n1kv_ctxt())
|
||||||
elif self.plugin == 'Calico':
|
elif self.plugin == 'Calico':
|
||||||
ctxt.update(self.calico_ctxt())
|
ctxt.update(self.calico_ctxt())
|
||||||
|
elif self.plugin == 'vsp':
|
||||||
|
ctxt.update(self.nuage_ctxt())
|
||||||
|
|
||||||
alchemy_flags = config('neutron-alchemy-flags')
|
alchemy_flags = config('neutron-alchemy-flags')
|
||||||
if alchemy_flags:
|
if alchemy_flags:
|
||||||
|
@ -180,6 +180,19 @@ def neutron_plugins():
|
|||||||
'nova-api-metadata']],
|
'nova-api-metadata']],
|
||||||
'server_packages': ['neutron-server', 'calico-control'],
|
'server_packages': ['neutron-server', 'calico-control'],
|
||||||
'server_services': ['neutron-server']
|
'server_services': ['neutron-server']
|
||||||
|
},
|
||||||
|
'vsp': {
|
||||||
|
'config': '/etc/neutron/plugins/nuage/nuage_plugin.ini',
|
||||||
|
'driver': 'neutron.plugins.nuage.plugin.NuagePlugin',
|
||||||
|
'contexts': [
|
||||||
|
context.SharedDBContext(user=config('neutron-database-user'),
|
||||||
|
database=config('neutron-database'),
|
||||||
|
relation_prefix='neutron',
|
||||||
|
ssl_dir=NEUTRON_CONF_DIR)],
|
||||||
|
'services': [],
|
||||||
|
'packages': [],
|
||||||
|
'server_packages': ['neutron-server', 'neutron-plugin-nuage'],
|
||||||
|
'server_services': ['neutron-server']
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if release >= 'icehouse':
|
if release >= 'icehouse':
|
||||||
|
@ -9,5 +9,9 @@ respawn
|
|||||||
exec start-stop-daemon --start --chuid {{ user_name }} \
|
exec start-stop-daemon --start --chuid {{ user_name }} \
|
||||||
--chdir {{ start_dir }} --name {{ process_name }} \
|
--chdir {{ start_dir }} --name {{ process_name }} \
|
||||||
--exec {{ executable_name }} -- \
|
--exec {{ executable_name }} -- \
|
||||||
|
{% for config_file in config_files -%}
|
||||||
--config-file={{ config_file }} \
|
--config-file={{ config_file }} \
|
||||||
|
{% endfor -%}
|
||||||
|
{% if log_file -%}
|
||||||
--log-file={{ log_file }}
|
--log-file={{ log_file }}
|
||||||
|
{% endif -%}
|
||||||
|
@ -33,9 +33,9 @@ def bool_from_string(value):
|
|||||||
|
|
||||||
value = value.strip().lower()
|
value = value.strip().lower()
|
||||||
|
|
||||||
if value in ['y', 'yes', 'true', 't']:
|
if value in ['y', 'yes', 'true', 't', 'on']:
|
||||||
return True
|
return True
|
||||||
elif value in ['n', 'no', 'false', 'f']:
|
elif value in ['n', 'no', 'false', 'f', 'off']:
|
||||||
return False
|
return False
|
||||||
|
|
||||||
msg = "Unable to interpret string value '%s' as boolean" % (value)
|
msg = "Unable to interpret string value '%s' as boolean" % (value)
|
||||||
|
@ -169,9 +169,9 @@ class CinderBasicDeployment(OpenStackAmuletDeployment):
|
|||||||
obj_count)
|
obj_count)
|
||||||
|
|
||||||
def obj_is_status(self, obj, obj_id, stat='available',
|
def obj_is_status(self, obj, obj_id, stat='available',
|
||||||
msg='openstack object status check', max_wait=60):
|
msg='openstack object status check', max_wait=120):
|
||||||
''''Wait for an openstack object status to be as expected.
|
''''Wait for an openstack object status to be as expected.
|
||||||
By default, expect an available status within 60s. Useful
|
By default, expect an available status within 120s. Useful
|
||||||
when confirming cinder volumes, snapshots, glance images, etc.
|
when confirming cinder volumes, snapshots, glance images, etc.
|
||||||
reach a certain state/status within a specified time.'''
|
reach a certain state/status within a specified time.'''
|
||||||
# NOTE(beisner): need to move to charmhelpers, and adjust calls here.
|
# NOTE(beisner): need to move to charmhelpers, and adjust calls here.
|
||||||
@ -301,7 +301,7 @@ class CinderBasicDeployment(OpenStackAmuletDeployment):
|
|||||||
'auth_protocol': 'http',
|
'auth_protocol': 'http',
|
||||||
'private-address': u.valid_ip,
|
'private-address': u.valid_ip,
|
||||||
'auth_host': u.valid_ip,
|
'auth_host': u.valid_ip,
|
||||||
'service_username': 'cinder',
|
'service_username': 'cinder_cinderv2',
|
||||||
'service_tenant_id': u.not_null,
|
'service_tenant_id': u.not_null,
|
||||||
'service_host': u.valid_ip
|
'service_host': u.valid_ip
|
||||||
}
|
}
|
||||||
@ -317,11 +317,11 @@ class CinderBasicDeployment(OpenStackAmuletDeployment):
|
|||||||
relation = ['identity-service',
|
relation = ['identity-service',
|
||||||
'keystone:identity-service']
|
'keystone:identity-service']
|
||||||
expected = {
|
expected = {
|
||||||
'service': 'cinder',
|
'cinder_service': 'cinder',
|
||||||
'region': 'RegionOne',
|
'cinder_region': 'RegionOne',
|
||||||
'public_url': u.valid_url,
|
'cinder_public_url': u.valid_url,
|
||||||
'internal_url': u.valid_url,
|
'cinder_internal_url': u.valid_url,
|
||||||
'admin_url': u.valid_url,
|
'cinder_admin_url': u.valid_url,
|
||||||
'private-address': u.valid_ip
|
'private-address': u.valid_ip
|
||||||
}
|
}
|
||||||
u.log.debug('')
|
u.log.debug('')
|
||||||
@ -508,7 +508,7 @@ class CinderBasicDeployment(OpenStackAmuletDeployment):
|
|||||||
|
|
||||||
def test_users(self):
|
def test_users(self):
|
||||||
'''Verify expected users.'''
|
'''Verify expected users.'''
|
||||||
user0 = {'name': 'cinder',
|
user0 = {'name': 'cinder_cinderv2',
|
||||||
'enabled': True,
|
'enabled': True,
|
||||||
'tenantId': u.not_null,
|
'tenantId': u.not_null,
|
||||||
'id': u.not_null,
|
'id': u.not_null,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user