Add MySQL connection SSL support
When 'tacker_galera_use_ssl' is True, use an encrypted connection to the database using either a self-signed or user-provided CA certificate. A new non-voting test has been added to verify that the role remains functional when enabling SSL features. Change-Id: I9165a04de869197ac05e60be799f59a263e98a7b Partial-Bug: 1667789
This commit is contained in:
parent
d95902891c
commit
edc9c555b3
|
@ -65,9 +65,11 @@ glance_rabbitmq_port: 5672
|
|||
glance_rabbitmq_servers: 127.0.0.1
|
||||
glance_rabbitmq_use_ssl: False
|
||||
|
||||
## DB info
|
||||
## Database info
|
||||
tacker_galera_database: tacker
|
||||
tacker_galera_user: tacker
|
||||
tacker_galera_use_ssl: "{{ galera_use_ssl | default(False) }}"
|
||||
tacker_galera_ssl_ca_cert: "{{ galera_ssl_ca_cert | default('/etc/ssl/certs/galera-ca.pem') }}"
|
||||
|
||||
tacker_role_name: admin
|
||||
tacker_bind_address: 0.0.0.0
|
||||
|
|
|
@ -93,7 +93,7 @@ auth_type = {{ tacker_keystone_auth_plugin }}
|
|||
# be set in the corresponding core plugin '.ini' file. However, it is suggested
|
||||
# to put the [database] section and its connection attribute in this
|
||||
# configuration file.
|
||||
connection = mysql://{{ tacker_galera_user }}:{{ tacker_container_mysql_password }}@{{ tacker_galera_address }}/{{ tacker_galera_database }}?charset=utf8
|
||||
connection = mysql://{{ tacker_galera_user }}:{{ tacker_container_mysql_password }}@{{ tacker_galera_address }}/{{ tacker_galera_database }}?charset=utf8{% if tacker_galera_use_ssl | bool %}&ssl_ca={{ tacker_galera_ssl_ca_cert }}{% endif %}
|
||||
|
||||
# Specify drivers for mgmt
|
||||
mgmt_driver = noop,openwrt
|
||||
|
|
12
tox.ini
12
tox.ini
|
@ -126,6 +126,18 @@ commands =
|
|||
bash -c "{toxinidir}/tests/tests-repo-clone.sh"
|
||||
bash -c "{toxinidir}/tests/common/test-ansible-functional.sh"
|
||||
|
||||
|
||||
[testenv:ssl]
|
||||
deps =
|
||||
{[testenv:ansible]deps}
|
||||
setenv =
|
||||
{[testenv]setenv}
|
||||
ANSIBLE_PARAMETERS=-vvv -e galera_use_ssl=True
|
||||
commands =
|
||||
bash -c "{toxinidir}/tests/tests-repo-clone.sh"
|
||||
bash -c "{toxinidir}/tests/common/test-ansible-functional.sh"
|
||||
|
||||
|
||||
[testenv:linters]
|
||||
deps =
|
||||
{[testenv:ansible]deps}
|
||||
|
|
|
@ -0,0 +1,21 @@
|
|||
---
|
||||
# Copyright 2017, Rackspace US, Inc.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
- job:
|
||||
name: openstack-ansible-tacker-ssl-nv
|
||||
parent: openstack-ansible-functional-ubuntu-xenial
|
||||
voting: false
|
||||
vars:
|
||||
tox_env: ssl
|
|
@ -20,6 +20,7 @@
|
|||
- openstack-ansible-linters
|
||||
- openstack-ansible-functional-opensuse-423
|
||||
- openstack-ansible-functional-ubuntu-xenial
|
||||
- openstack-ansible-tacker-ssl-nv
|
||||
experimental:
|
||||
jobs:
|
||||
- openstack-ansible-integrated-deploy-aio
|
||||
|
@ -28,3 +29,4 @@
|
|||
- openstack-ansible-linters
|
||||
- openstack-ansible-functional-opensuse-423
|
||||
- openstack-ansible-functional-ubuntu-xenial
|
||||
- openstack-ansible-tacker-ssl-nv
|
||||
|
|
Loading…
Reference in New Issue