Sync charm-helpers
Change-Id: Idd5bc62d5ee87f729b033dc37ae9959a8725f5c5
This commit is contained in:
parent
97a6f8ef2a
commit
63e590b6af
@ -97,6 +97,7 @@ from charmhelpers.contrib.network.ip import (
|
||||
)
|
||||
from charmhelpers.contrib.openstack.utils import (
|
||||
config_flags_parser,
|
||||
get_os_codename_install_source,
|
||||
enable_memcache,
|
||||
CompareOpenStackReleases,
|
||||
os_release,
|
||||
@ -240,6 +241,8 @@ class SharedDBContext(OSContextGenerator):
|
||||
else:
|
||||
rids = relation_ids(self.interfaces[0])
|
||||
|
||||
rel = (get_os_codename_install_source(config('openstack-origin')) or
|
||||
'icehouse')
|
||||
for rid in rids:
|
||||
self.related = True
|
||||
for unit in related_units(rid):
|
||||
@ -253,6 +256,8 @@ class SharedDBContext(OSContextGenerator):
|
||||
'database_password': rdata.get(password_setting),
|
||||
'database_type': 'mysql+pymysql'
|
||||
}
|
||||
if CompareOpenStackReleases(rel) < 'stein':
|
||||
ctxt['database_type'] = 'mysql'
|
||||
if self.context_complete(ctxt):
|
||||
db_ssl(rdata, ctxt, self.ssl_dir)
|
||||
return ctxt
|
||||
|
Loading…
Reference in New Issue
Block a user