Esempio n. 1
0
def register_configs(release=None):
    resources = OrderedDict([(HAPROXY_CONF, {
        'services': ['haproxy'],
        'contexts': [
            context.HAProxyContext(singlenode_mode=True),
            cplane_context.HAProxyContext()
        ],
    })])
    release = config('openstack-version')
    configs = templating.OSConfigRenderer(templates_dir=TEMPLATES,
                                          openstack_release=release)
    for cfg, rscs in resources.iteritems():
        configs.register(cfg, rscs['contexts'])
    return configs
Esempio n. 2
0
                                        template_flag='api_config_flags'),
            context.InternalEndpointContext('glance-common'),
            context.SubordinateConfigContext(interface=['storage-backend'],
                                             service=['glance-api'],
                                             config_file=GLANCE_API_CONF),
            context.MemcacheContext()
        ],
        'services': ['glance-api']
    }),
    (ceph_config_file(), {
        'hook_contexts': [context.CephContext()],
        'services': ['glance-api', 'glance-registry']
    }),
    (HAPROXY_CONF, {
        'hook_contexts': [
            context.HAProxyContext(singlenode_mode=True),
            glance_contexts.HAProxyContext()
        ],
        'services': ['haproxy'],
    }),
    (HTTPS_APACHE_CONF, {
        'hook_contexts': [glance_contexts.ApacheSSLContext()],
        'services': ['apache2'],
    }),
    (HTTPS_APACHE_24_CONF, {
        'hook_contexts': [glance_contexts.ApacheSSLContext()],
        'services': ['apache2'],
    })
])

Esempio n. 3
0
 (APACHE_DEFAULT, {
     'hook_contexts': [horizon_contexts.ApacheContext()],
     'services': ['apache2', 'memcached'],
 }),
 (APACHE_24_DEFAULT, {
     'hook_contexts': [horizon_contexts.ApacheContext()],
     'services': ['apache2', 'memcached'],
 }),
 (PORTS_CONF, {
     'hook_contexts': [horizon_contexts.ApacheContext()],
     'services': ['apache2', 'memcached'],
 }),
 (HAPROXY_CONF, {
     'hook_contexts': [
         horizon_contexts.HorizonHAProxyContext(),
         context.HAProxyContext(singlenode_mode=True, address_types=[]),
     ],
     'services': ['haproxy'],
 }),
 (ROUTER_SETTING, {
     'hook_contexts': [horizon_contexts.RouterSettingContext()],
     'services': ['apache2', 'memcached'],
 }),
 (KEYSTONEV3_POLICY, {
     'hook_contexts': [horizon_contexts.IdentityServiceContext()],
     'services': ['apache2', 'memcached'],
 }),
 (CONSISTENCY_GROUP_POLICY, {
     'hook_contexts': [horizon_contexts.HorizonContext()],
     'services': ['apache2', 'memcached'],
 }),
                          LoggingConfigContext(),
                          MongoDBContext(),
                          CeilometerContext(),
                          context.SyslogContext(),
                          HAProxyContext(),
                          context.MemcacheContext(),
                          MetricServiceContext(),
                          context.WorkerConfigContext()],
        'services': CEILOMETER_BASE_SERVICES
    }),
    (CEILOMETER_API_SYSTEMD_CONF, {
        'hook_contexts': [HAProxyContext()],
        'services': ['ceilometer-api'],
    }),
    (HAPROXY_CONF, {
        'hook_contexts': [context.HAProxyContext(singlenode_mode=True),
                          HAProxyContext()],
        'services': ['haproxy'],
    }),
    (HTTPS_APACHE_CONF, {
        'hook_contexts': [ApacheSSLContext()],
        # Include ceilometer-api to fix Bug #1632287 This is a temporary
        # tactival fix as the charm will be rewritten to use mod_wsgi next
        # cycle
        'services': ['ceilometer-api', 'apache2'],
    }),
    (HTTPS_APACHE_24_CONF, {
        'hook_contexts': [ApacheSSLContext()],
        'services': ['ceilometer-api', 'apache2'],
    }),
])