MySQL: change default MySQL collate to utf8_general_ci
Install & configure MySQL database by using utf8_general_ci collation
which is the way documented in OpenStack [1] and already the default
in puppetlabs-mysql [2].
[1] http://goo.gl/GA5gyZ
[2] https://github.com/puppetlabs/puppetlabs-mysql/blob/master/manifests/db.pp#L7
Change-Id: I7ceecaa3e7fe964e53714cfd4c6fd2b8ff90fce0
Closes-bug: #1446375
(cherry picked from commit 6122ac4ebb
)
This commit is contained in:
parent
417121b83c
commit
176d7d6591
@ -110,7 +110,7 @@ string; optional; default to 'utf8'
|
||||
|
||||
#####`collate`
|
||||
The collate to use for the database;
|
||||
string; optional; default to 'utf8_unicode_ci'
|
||||
string; optional; default to 'utf8_general_ci'
|
||||
|
||||
#####`allowed_hosts`
|
||||
Additional hosts that are allowed to access this database;
|
||||
|
@ -26,7 +26,7 @@
|
||||
#
|
||||
# [*collate*]
|
||||
# The collate to use for the database;
|
||||
# string; optional; default to 'utf8_unicode_ci'
|
||||
# string; optional; default to 'utf8_general_ci'
|
||||
#
|
||||
# [*allowed_hosts*]
|
||||
# Additional hosts that are allowed to access this database;
|
||||
@ -42,7 +42,7 @@ define openstacklib::db::mysql (
|
||||
$user = $title,
|
||||
$host = '127.0.0.1',
|
||||
$charset = 'utf8',
|
||||
$collate = 'utf8_unicode_ci',
|
||||
$collate = 'utf8_general_ci',
|
||||
$allowed_hosts = [],
|
||||
$privileges = 'ALL',
|
||||
) {
|
||||
|
@ -21,7 +21,7 @@ describe 'openstacklib::db::mysql' do
|
||||
|
||||
it { should contain_mysql_database(title).with(
|
||||
:charset => 'utf8',
|
||||
:collate => 'utf8_unicode_ci'
|
||||
:collate => 'utf8_general_ci'
|
||||
)}
|
||||
it { should contain_openstacklib__db__mysql__host_access("#{title}_127.0.0.1").with(
|
||||
:user => title,
|
||||
@ -37,7 +37,7 @@ describe 'openstacklib::db::mysql' do
|
||||
|
||||
it { should contain_mysql_database(params[:dbname]).with(
|
||||
:charset => 'utf8',
|
||||
:collate => 'utf8_unicode_ci'
|
||||
:collate => 'utf8_general_ci'
|
||||
)}
|
||||
it { should contain_openstacklib__db__mysql__host_access("#{params[:dbname]}_127.0.0.1").with(
|
||||
:user => title,
|
||||
@ -53,12 +53,12 @@ describe 'openstacklib::db::mysql' do
|
||||
|
||||
it { should contain_mysql_database(title).with(
|
||||
:charset => 'utf8',
|
||||
:collate => 'utf8_unicode_ci'
|
||||
:collate => 'utf8_general_ci'
|
||||
)}
|
||||
it { should contain_openstacklib__db__mysql__host_access("#{title}_127.0.0.1").with(
|
||||
:user => params[:user],
|
||||
:database => title,
|
||||
:privileges => 'ALL'
|
||||
:privileges => 'ALL',
|
||||
)}
|
||||
end
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user