Adjust to per-service configuration

Change-Id: I96184590231b48aedf695296460ededff0cd6e7b
Depends-On: Ia4d29167cea6dfd19a1970706aafda51a31d5b24
This commit is contained in:
Andrey Pavlov 2017-02-27 09:43:08 +00:00
parent 0a8d89a7bc
commit 0f96e25685
3 changed files with 6 additions and 6 deletions

View File

@ -11,12 +11,11 @@ host = {{ network_topology["private"]["address"] }}
port = {{ sahara.port.cont }}
periodic_coordinator_backend_url = memcached://{{ address("memcached", memcached.port) }}
transport_url = rabbit://{{ rabbitmq.user }}:{{ rabbitmq.password }}@{{ address("rabbitmq", rabbitmq.port) }}/
heat_enable_wait_condition = {{ sahara.enable_wait_condition }}
[database]
connection = mysql+pymysql://{{ sahara.db.username }}:{{ sahara.db.password }}@{{ address(service.database) }}/{{ sahara.db.name }}{% if db.tls.enabled %}?ssl_ca=/opt/ccp/etc/tls/ca.pem{% endif %}
connection = mysql+pymysql://{{ sahara.db.username }}:{{ sahara.db.password }}@{{ address("database") }}/{{ sahara.db.name }}{% if db.tls.enabled %}?ssl_ca=/opt/ccp/etc/tls/ca.pem{% endif %}
max_retries = -1
{{ keystone_authtoken.keystone_authtoken(sahara.auth.user, sahara.auth.password) }}
@ -28,3 +27,5 @@ admin_tenant_name = {{ openstack.project_name }}
[oslo_messaging_notifications]
driver = noop
{{ oslo_messaging[messaging.backend.rpc]('rpc_config') }}

View File

@ -10,10 +10,10 @@ service:
pre:
- name: sahara-db-create
dependencies:
- {{ service.database }}
- database
type: single
command:
mysql -u root -p{{ db.root_password }} -h {{ address(service.database) }} -e "create database {{ sahara.db.name }};
mysql -u root -p{{ db.root_password }} -h {{ address("database") }} -e "create database {{ sahara.db.name }};
create user '{{ sahara.db.username }}'@'%' identified by '{{ sahara.db.password }}'
{% if db.tls.enabled %} require ssl {% endif %};
grant all privileges on {{ sahara.db.name }}.* to '{{ sahara.db.username }}'@'%' identified by '{{ sahara.db.password }}'
@ -59,7 +59,7 @@ service:
files:
- sahara-conf
dependencies:
- rabbitmq
- rpc
command: sahara-api --config-file /etc/sahara/sahara.conf
files:

View File

@ -9,7 +9,6 @@ service:
files:
- sahara-conf
dependencies:
- rabbitmq
- sahara-api
command: sahara-engine --config-file /etc/sahara/sahara.conf