Tidy lint

This commit is contained in:
James Page 2014-07-15 16:57:34 +01:00
parent 386a375afa
commit cef1a05bed
4 changed files with 12 additions and 11 deletions

View File

@ -55,7 +55,6 @@ from keystone_utils import (
from charmhelpers.contrib.hahelpers.cluster import (
eligible_leader,
get_hacluster_config,
is_leader,
)
@ -228,7 +227,7 @@ def ha_joined():
if len(vip_group) > 1:
relation_set(groups={'grp_glance_vips': ' '.join(vip_group)})
init_services = {
'res_ks_haproxy': 'haproxy'
}

View File

@ -518,7 +518,7 @@ def create_keystone_endpoint(public_ip, service_port,
internal_ip = "[{}]".format(internal_ip)
if is_ipv6(admin_ip):
admin_ip = "[{}]".format(admin_ip)
public_url = "%s://%s:%s/v2.0" % (proto, public_ip, service_port)
admin_url = "%s://%s:%s/v2.0" % (proto, admin_ip, auth_port)
internal_url = "%s://%s:%s/v2.0" % (proto, internal_ip, service_port)
@ -644,10 +644,12 @@ def add_service_to_keystone(relation_id=None, remote_unit=None):
relation_data["auth_host"] = config('vip')
relation_data["service_host"] = config('vip')
else:
relation_data["auth_host"] = get_address_in_network(config('os-admin-network'),
unit_private_ip())
relation_data["service_host"] = get_address_in_network(config('os-public-network'),
unit_private_ip())
relation_data["auth_host"] = \
get_address_in_network(config('os-admin-network'),
unit_private_ip())
relation_data["service_host"] = \
get_address_in_network(config('os-public-network'),
unit_private_ip())
if https():
relation_data["auth_protocol"] = "https"
relation_data["service_protocol"] = "https"

View File

@ -62,7 +62,7 @@ TO_PATCH = [
'time',
# ip
'get_iface_for_address',
'get_netmask_for_address',
'get_netmask_for_address',
]

View File

@ -80,9 +80,9 @@ class TestConfig(object):
return self.config
def set(self, attr, value):
if attr not in self.config:
raise KeyError
self.config[attr] = value
if attr not in self.config:
raise KeyError
self.config[attr] = value
class TestRelation(object):