... and migrate it to openstacklib so that all logics about database
configuration are implemented in one common place.
Depends-on: https://review.opendev.org/#/c/728595/
Change-Id: Ie564c3ae6023a36f317b963872059509754970e5
This changes all the puppet 3 validate_* functions
to use the validate_legacy function.
The validate_legacy function has been available since
about three years but require Puppet >= 4.4.0 and since
there is Puppet 4.10.12 as latest we should assume people
are running a fairly new Puppet 4 version.
This is the first step to then remove all validate function
calls and use proper types for parameter as described in spec [1].
[1] https://review.openstack.org/#/c/568929/
Depends-On: https://review.openstack.org/#/c/639215/
Change-Id: Idd720f18893bea0ec1d26859e0a6907a5daa8980
Make sure documentation is the same and follow
the standard which we are trying to enforce on
all modules.
Change-Id: I215f28f4ce417a3c098cbf4be21967b2ed4013bb
This code moves all deps to an external class so that Keystone can be
installed with mechanisms besides packages (like venv or docker). This
also cleans-up the dependency tree by removing false or confusing
dependencies.
Change-Id: If69cd7cba267f75faad51fdbc80a58b24d2095d8
Co-Author: Clayton O'Neill <clayton.oneill@twcable.com>
Un-pin puppet-lint gem and add puppet-lint-param-docs, this commit also
add missing puppetdoc and fixes lint issues.
Change-Id: I1eefc743c68c75eb54a65b3cc539922ef3a3b04d
When using version >= 2.2 of the MySQL module, setting up
the database for Keystone depended on the MySQL service
(Service['mysqld']). However, if the service is not managed
by Puppet (e.g. it is managed through Pacemaker instead),
this would cause catalog compilation to fail because there
is no Service['mysqld']. This is the case when the MySQL
module is called with service_manage => false. Requiring
Class['mysql::server'] instead fixes this.
Change-Id: Ia1b34051dd6e4fc0916ac788d6027c1f987418a8
Closes-Bug: 1349316
Version 2.2+ of the puppetlabs-mysql moudule starts the MySQL database
with the Service resource name mysqld [1]. The puppet-keystone module
lists a requirement for a Service resource with name mysql. This will
lead to an undefined resource error.
This patch corrects the dependency.
[1] https://github.com/puppetlabs/puppetlabs-mysql/blob/master/manifests/server/service.pp#L15
Change-Id: I2165b2c0529c0ecd9e9ba9853f3d15d5f86b0135
The keystone::db::mysql resource declares resources using
`$real_allowed_hosts` which is a copy of `$allowed_hosts` minus `$host`.
But then it declares dependencies using `$allowed_hosts` which includes
`$host` and will fail catalog compilation due to a missing dependency
This bug only affects users if the value of `$host` is included in the
array of `$allowed_hosts`
Change-Id: Ifdd8793bcf36178efd1a083ee35649d56dc3d768
Puppetlabs-mysql has been rewritten to be much
cleaner. This patch adds a new parameter for the
keystone mysql and init classes allowing users to
use the new version. Previous behavior will continue
as normal when using the old version (0.9)
Change-Id: Idf7c46d9aab8db7cca7d8377431c60b24ae4c9c6
Closes-bug: #1266241
The current default db username for keystone is
keystone_admin. This is inconsistent with the default
db username for every other service which use the
same name as the name of the service.
The documented installation instruction for keystone
also use keystone as the database user.
This commit updates the default to use keystone instead of
keyston_admin.
Change-Id: I1cfaf3fbbc691ff9dbef415b69492f9f965dc113
In the origin keystone::db::mysql, if the value of $allowed_hosts
contains or equals to $host, then puppet will complain duplicate
declaration error. This patch is aim to update the allowed_hosts
conditonal statement in keystone::db::mysql.
There are two cases to pass $allowed_hosts to $real_allowed_hosts:
- If $allowed_hosts is array,then remove $host from $allowed_hosts;
- elsif $allowed_hosts is string and not equivalent to $host;
At last, if $real_allowed_hosts is not undef, then run
keystone::db::mysql::host_access
Fix bug 1206444
Change-Id: I8701aea9344a9151ce3d7ac8fa5792895a5aac6c
Previously, the db::mysql class required mysql::server. This is
unnecessary since the mysql::db define requires the mysql::config
class for db creattion. Additionally, this prevents users from
using a different class such as galera::server to manage
the database.
Change-Id: Ifb0fa261f9f5921cf9fe5b309decceab608d4726
* Fixes following warnings:
* indentation of => is not properly aligned
* string containing only a variable
* Fixes following errors:
* tab character found
* two-space soft tabs not used
* Remove quotes around class in include/require statements
Change-Id: I7e17d9153d413792e32f9d7c430dfbd37852ba51
Since keystone can use different databases, it makes
sense to move the mysql classes to db::mysql. This way
there is a clear standard for where other DB implementations
should be located.
This commit moves keystone::mysql to keystone::db::mysql
and keystone::mysql::access to keystone::db::mysql::host_access.