File tree Expand file tree Collapse file tree 4 files changed +20
-70
lines changed Expand file tree Collapse file tree 4 files changed +20
-70
lines changed Original file line number Diff line number Diff line change @@ -512,7 +512,6 @@ class { 'mysql::server::backup':
512512#### Public classes
513513
514514* [ ` mysql::server ` ] ( #mysqlserver ) : Installs and configures MySQL.
515- * [ ` mysql::server::monitor ` ] ( #mysqlservermonitor ) : Sets up a monitoring user.
516515* [ ` mysql::server::mysqltuner ` ] ( #mysqlservermysqltuner ) : Installs MySQL tuner script.
517516* [ ` mysql::server::backup ` ] ( #mysqlserverbackup ) : Sets up MySQL backups via cron.
518517* [ ` mysql::bindings ` ] ( #mysqlbindings ) : Installs various MySQL language bindings.
Original file line number Diff line number Diff line change 1+ # @summary
2+ # Add a monitoring user to the database
3+
4+ $mysql_monitor_password = ' password'
5+ $mysql_monitor_username = ' monitoring'
6+ $mysql_monitor_hostname = $::facts [' networking' ][' hostname' ]
7+
8+ mysql_user { "${mysql_monitor_username}@${mysql_monitor_hostname}" :
9+ ensure => present ,
10+ password_hash => mysql::password($mysql_monitor_password ),
11+ require => Class[' mysql::server::service' ],
12+ }
13+
14+ mysql_grant { "${mysql_monitor_username}@${mysql_monitor_hostname}/*.*" :
15+ ensure => present ,
16+ user => " ${mysql_monitor_username} @${mysql_monitor_hostname} " ,
17+ table => ' *.*' ,
18+ privileges => [' PROCESS' , ' SUPER' ],
19+ require => Mysql_user[" ${mysql_monitor_username} @${mysql_monitor_hostname} " ],
20+ }
Load Diff This file was deleted.
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments