diff options
author | mh <mh@immerda.ch> | 2013-01-02 18:48:49 +0100 |
---|---|---|
committer | mh <mh@immerda.ch> | 2013-01-02 18:48:49 +0100 |
commit | c1c3b112459f995afdaae9cc9aa415ea68788596 (patch) | |
tree | f70bea4dc3bb258e5c84d1942dca43515be2fdee /manifests/server | |
parent | 2e57128b061d65e3c54297b4cd7d3759625a3dce (diff) |
make trocla an optional dependency
Diffstat (limited to 'manifests/server')
-rw-r--r-- | manifests/server/munin/default.pp | 9 | ||||
-rw-r--r-- | manifests/server/nagios.pp | 2 |
2 files changed, 5 insertions, 6 deletions
diff --git a/manifests/server/munin/default.pp b/manifests/server/munin/default.pp index 11609d2..91cd5fe 100644 --- a/manifests/server/munin/default.pp +++ b/manifests/server/munin/default.pp @@ -1,7 +1,7 @@ # manage plugins class mysql::server::munin::default { mysql_user{'munin@localhost': - password_hash => trocla("mysql_munin_${::fqdn}",'mysql','length: 32'), + password_hash => mysql_password($mysql::server::munin_password), require => Exec['mysql_set_rootpw'], } @@ -10,18 +10,17 @@ class mysql::server::munin::default { require => Mysql_user['munin@localhost'], } - $munin_mysql_password = trocla("mysql_munin_${::fqdn}",'plain', 'length: 32') munin::plugin { [mysql_queries, mysql_slowqueries]: - config => "env.mysqlopts --user=munin --password='${munin_mysql_password}' -h localhost", + config => "env.mysqlopts --user=munin --password='${mysql::server::munin_password}' -h localhost", require => Mysql_grant['munin@localhost']; [mysql_bytes, mysql_threads]: - config => "env.mysqlopts --user=munin --password=${munin_mysql_password} -h localhost", + config => "env.mysqlopts --user=munin --password=${mysql::server::munin_password} -h localhost", require => Mysql_grant['munin@localhost']; } Munin::Plugin::Deploy{ - config => "env.mysqlopts --user=munin --password='${munin_mysql_password}' -h localhost", + config => "env.mysqlopts --user=munin --password='${mysql::server::munin_password}' -h localhost", require => Mysql_grant['munin@localhost'], } munin::plugin::deploy{ diff --git a/manifests/server/nagios.pp b/manifests/server/nagios.pp index 944e0dd..34bb086 100644 --- a/manifests/server/nagios.pp +++ b/manifests/server/nagios.pp @@ -13,7 +13,7 @@ class mysql::server::nagios { } mysql_user{$nagios_mysql_user: - password_hash => trocla("mysql_nagios_${::fqdn}",'mysql','length: 32'), + password_hash => $mysql::server::nagios_password_hash, require => Package['mysql'], } |