Skip to content

Commit

Permalink
Check for full path for log-bin to stop puppet from managing director…
Browse files Browse the repository at this point in the history
…y “.”
  • Loading branch information
NoodlesNZ committed Feb 11, 2015
1 parent b64ca51 commit dc71156
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions manifests/server/config.pp
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,16 @@
$logbin = pick($options['mysqld']['log-bin'], $options['mysqld']['log_bin'], false)

if $logbin {
$logbindir = mysql_dirname($logbin)
file { $logbindir:
ensure => directory,
mode => '0755',
owner => $options['mysqld']['user'],
group => $options['mysqld']['user'],
$logbindir = dirname($logbin)

#Stop puppet from managing directory if just a filename/prefix is specified
if $logbindir != '.' {
file { $logbindir:
ensure => directory,
mode => '0755',
owner => $options['mysqld']['user'],
group => $options['mysqld']['user'],
}
}
}

Expand Down

0 comments on commit dc71156

Please sign in to comment.