Merge "Add DB SSL support"

This commit is contained in:
Jenkins 2017-02-15 15:58:49 +00:00 committed by Gerrit Code Review
commit ab49111358
2 changed files with 5 additions and 2 deletions

View File

@ -16,7 +16,7 @@ reauthentication_auth_method = trusts
endpoint_type = internalURL endpoint_type = internalURL
[database] [database]
connection = mysql+pymysql://{{ heat.db.username }}:{{ heat.db.password }}@{{ address(service.database) }}/{{ heat.db.name }} connection = mysql+pymysql://{{ heat.db.username }}:{{ heat.db.password }}@{{ address(service.database) }}/{{ heat.db.name }}{% if percona.tls.enabled %}?ssl_ca=/opt/ccp/etc/tls/ca.pem{% endif %}
[keystone_authtoken] [keystone_authtoken]
auth_version = v3 auth_version = v3

View File

@ -13,7 +13,10 @@ service:
type: single type: single
command: command:
mysql -u root -p{{ db.root_password }} -h {{ address(service.database) }} -e "create database {{ heat.db.name }}; mysql -u root -p{{ db.root_password }} -h {{ address(service.database) }} -e "create database {{ heat.db.name }};
grant all privileges on {{ heat.db.name }}.* to '{{ heat.db.username }}'@'%' identified by '{{ heat.db.password }}';" create user '{{ heat.db.username }}'@'%' identified by '{{ heat.db.password }}'
{% if percona.tls.enabled %} require ssl {% endif %};
grant all privileges on {{ heat.db.name }}.* to '{{ heat.db.username }}'@'%' identified by '{{ heat.db.password }}'
{% if percona.tls.enabled %} require ssl {% endif %};"
- name: heat-db-sync - name: heat-db-sync
files: files:
- heat-conf - heat-conf