Move constants to glance_utils
This commit is contained in:
parent
999904f47e
commit
0aaf0853b6
|
@ -9,11 +9,15 @@ from glance_utils import (
|
|||
migrate_database,
|
||||
register_configs,
|
||||
restart_map,
|
||||
set_ceph_env_variables)
|
||||
set_ceph_env_variables,
|
||||
CLUSTER_RES,
|
||||
PACKAGES,
|
||||
SERVICES,
|
||||
CHARM,
|
||||
SERVICE_NAME, )
|
||||
|
||||
from charmhelpers.core.hookenv import (
|
||||
log as juju_log,
|
||||
service_name,
|
||||
relation_set,
|
||||
relation_ids,
|
||||
unit_get)
|
||||
|
@ -46,21 +50,8 @@ from subprocess import (
|
|||
|
||||
from commands import getstatusoutput
|
||||
|
||||
CLUSTER_RES = "res_glance_vip"
|
||||
|
||||
CONFIGS = register_configs()
|
||||
|
||||
|
||||
PACKAGES = [
|
||||
"apache2", "glance", "python-mysqldb", "python-swift",
|
||||
"python-keystone", "uuid", "haproxy", ]
|
||||
|
||||
SERVICES = [
|
||||
"glance-api", "glance-registry", ]
|
||||
|
||||
CHARM = "glance"
|
||||
SERVICE_NAME = service_name()
|
||||
|
||||
config = json.loads(check_output(['config-get', '--format=json']))
|
||||
|
||||
|
||||
|
|
|
@ -12,7 +12,8 @@ from collections import OrderedDict
|
|||
from charmhelpers.core.hookenv import (
|
||||
relation_get,
|
||||
relation_ids,
|
||||
related_units, )
|
||||
related_units,
|
||||
service_name, )
|
||||
|
||||
from charmhelpers.contrib.openstack import (
|
||||
templating,
|
||||
|
@ -32,6 +33,20 @@ from charmhelpers.contrib.openstack.openstack_utils import (
|
|||
get_os_codename_package,
|
||||
configure_installation_source, )
|
||||
|
||||
CONFIGS = register_configs()
|
||||
|
||||
CLUSTER_RES = "res_glance_vip"
|
||||
|
||||
PACKAGES = [
|
||||
"apache2", "glance", "python-mysqldb", "python-swift",
|
||||
"python-keystone", "uuid", "haproxy", ]
|
||||
|
||||
SERVICES = [
|
||||
"glance-api", "glance-registry", ]
|
||||
|
||||
CHARM = "glance"
|
||||
SERVICE_NAME = service_name()
|
||||
|
||||
GLANCE_REGISTRY_CONF = "/etc/glance/glance-registry.conf"
|
||||
GLANCE_REGISTRY_PASTE_INI = "/etc/glance/glance-registry-paste.ini"
|
||||
GLANCE_API_CONF = "/etc/glance/glance-api.conf"
|
||||
|
|
Loading…
Reference in New Issue