Merge pull request #742 from redhat-cip/idempotent-config
Ensure idempotency between Puppet runs
This commit is contained in:
commit
c7de52013b
2 changed files with 6 additions and 4 deletions
|
@ -37,9 +37,10 @@ class mysql::server::config {
|
|||
|
||||
if $mysql::server::manage_config_file {
|
||||
file { 'mysql-config-file':
|
||||
path => $mysql::server::config_file,
|
||||
content => template('mysql/my.cnf.erb'),
|
||||
mode => '0644',
|
||||
path => $mysql::server::config_file,
|
||||
content => template('mysql/my.cnf.erb'),
|
||||
mode => '0644',
|
||||
selinux_ignore_defaults => true,
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -11,7 +11,8 @@ describe 'mysql::server' do
|
|||
let(:params) {{ :override_options => { 'mysqld' => { 'socket' => '/var/lib/mysql/mysql.sock' } } }}
|
||||
it do
|
||||
is_expected.to contain_file('mysql-config-file').with({
|
||||
:mode => '0644',
|
||||
:mode => '0644',
|
||||
:selinux_ignore_defaults => true,
|
||||
}).with_content(/socket = \/var\/lib\/mysql\/mysql.sock/)
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue