b1f90fd1d2
This is a major change to the module and would be released as a new version. * Add self.instances to database and database_user for puppet resource. * Update database provider to use flush method. * Update module to conform to puppet-lint recommendations. * Cleanup some unecessary logic in mysql::db define type. * Move mysql_restart to config class. * Use class to class dependency instead of resource dependency. * Change appropriate rspec-puppet tests. * Add fixtures directory to simplify testing. * Update raketask and spec_helper to reflect fixture changes. * Update mysql_password function to support validation. * Move client installation to a separate class. * Update documentation and readme.
19 lines
557 B
Puppet
19 lines
557 B
Puppet
class mysql::server::monitor (
|
|
$mysql_monitor_username,
|
|
$mysql_monitor_password,
|
|
$mysql_monitor_hostname
|
|
) {
|
|
|
|
class ['mysql::server'] -> class['mysql::monitor']
|
|
|
|
database_user{ "${mysql_monitor_username}@${mysql_monitor_hostname}":
|
|
password_hash => mysql_password($mysql_monitor_password),
|
|
ensure => present,
|
|
}
|
|
|
|
database_grant { "${mysql_monitor_username}@${mysql_monitor_hostname}":
|
|
privileges => [ 'process_priv', 'super_priv' ],
|
|
require => Mysql_user["${mysql_monitor_username}@${mysql_monitor_hostname}"],
|
|
}
|
|
|
|
}
|