added syslog support
This commit is contained in:
parent
dc02e63d39
commit
7b9573beea
@ -36,6 +36,12 @@ options:
|
|||||||
rbd pool has been created, changing this value will not have any
|
rbd pool has been created, changing this value will not have any
|
||||||
effect (although it can be changed in ceph by manually configuring
|
effect (although it can be changed in ceph by manually configuring
|
||||||
your ceph cluster).
|
your ceph cluster).
|
||||||
|
use-syslog:
|
||||||
|
type: boolean
|
||||||
|
default: False
|
||||||
|
description: |
|
||||||
|
By default, all services will log into their corresponding log files.
|
||||||
|
Setting this to True will force all services to log to the syslog.
|
||||||
# HA configuration settings
|
# HA configuration settings
|
||||||
vip:
|
vip:
|
||||||
type: string
|
type: string
|
||||||
|
@ -2,6 +2,7 @@ from charmhelpers.core.hookenv import (
|
|||||||
is_relation_made,
|
is_relation_made,
|
||||||
relation_ids,
|
relation_ids,
|
||||||
service_name,
|
service_name,
|
||||||
|
config
|
||||||
)
|
)
|
||||||
|
|
||||||
from charmhelpers.contrib.openstack.context import (
|
from charmhelpers.contrib.openstack.context import (
|
||||||
@ -75,3 +76,11 @@ class ApacheSSLContext(SSLContext):
|
|||||||
|
|
||||||
def __call__(self):
|
def __call__(self):
|
||||||
return super(ApacheSSLContext, self).__call__()
|
return super(ApacheSSLContext, self).__call__()
|
||||||
|
|
||||||
|
|
||||||
|
class GlanceContext(OSContextGenerator):
|
||||||
|
def __call__(self):
|
||||||
|
ctxt = {
|
||||||
|
'use_syslog': config('use-syslog')
|
||||||
|
}
|
||||||
|
return ctxt
|
||||||
|
@ -63,7 +63,8 @@ TEMPLATES = 'templates/'
|
|||||||
CONFIG_FILES = OrderedDict([
|
CONFIG_FILES = OrderedDict([
|
||||||
(GLANCE_REGISTRY_CONF, {
|
(GLANCE_REGISTRY_CONF, {
|
||||||
'hook_contexts': [context.SharedDBContext(),
|
'hook_contexts': [context.SharedDBContext(),
|
||||||
context.IdentityServiceContext()],
|
context.IdentityServiceContext(),
|
||||||
|
glance_contexts.GlanceContext()],
|
||||||
'services': ['glance-registry']
|
'services': ['glance-registry']
|
||||||
}),
|
}),
|
||||||
(GLANCE_API_CONF, {
|
(GLANCE_API_CONF, {
|
||||||
@ -72,7 +73,8 @@ CONFIG_FILES = OrderedDict([
|
|||||||
context.IdentityServiceContext(),
|
context.IdentityServiceContext(),
|
||||||
glance_contexts.CephGlanceContext(),
|
glance_contexts.CephGlanceContext(),
|
||||||
glance_contexts.ObjectStoreContext(),
|
glance_contexts.ObjectStoreContext(),
|
||||||
glance_contexts.HAProxyContext()],
|
glance_contexts.HAProxyContext(),
|
||||||
|
glance_contexts.GlanceContext()],
|
||||||
'services': ['glance-api']
|
'services': ['glance-api']
|
||||||
}),
|
}),
|
||||||
(GLANCE_API_PASTE_INI, {
|
(GLANCE_API_PASTE_INI, {
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
[DEFAULT]
|
[DEFAULT]
|
||||||
verbose = True
|
verbose = True
|
||||||
|
use_syslog = {{ use_syslog }}
|
||||||
debug = True
|
debug = True
|
||||||
{% if rbd_pool %}
|
{% if rbd_pool %}
|
||||||
default_store = rbd
|
default_store = rbd
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
[DEFAULT]
|
[DEFAULT]
|
||||||
verbose = True
|
verbose = True
|
||||||
|
use_syslog = {{ use_syslog }}
|
||||||
debug = True
|
debug = True
|
||||||
{% if rbd_pool %}
|
{% if rbd_pool %}
|
||||||
default_store = rbd
|
default_store = rbd
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
[DEFAULT]
|
[DEFAULT]
|
||||||
verbose = True
|
verbose = True
|
||||||
|
use_syslog = {{ use_syslog }}
|
||||||
debug = True
|
debug = True
|
||||||
bind_host = 0.0.0.0
|
bind_host = 0.0.0.0
|
||||||
bind_port = 9191
|
bind_port = 9191
|
||||||
|
Loading…
x
Reference in New Issue
Block a user