aboutsummaryrefslogtreecommitdiff
path: root/manifests
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2010-06-20 12:17:49 -0300
committerSilvio Rhatto <rhatto@riseup.net>2010-06-20 12:17:49 -0300
commit61375314df8929d7c89d102b8f2f228db605b8b8 (patch)
tree4b857dcfc6ff176945941cd3238b3dee9bf27059 /manifests
parenta8f74b1e7709c24eee5b9ac9664e23d7781aa26e (diff)
downloadpuppet-nodo-61375314df8929d7c89d102b8f2f228db605b8b8.tar.gz
puppet-nodo-61375314df8929d7c89d102b8f2f228db605b8b8.tar.bz2
Just granting if db/user is present at database::instance
Diffstat (limited to 'manifests')
-rw-r--r--manifests/subsystems/database.pp8
1 files changed, 5 insertions, 3 deletions
diff --git a/manifests/subsystems/database.pp b/manifests/subsystems/database.pp
index 99c43f9..b896c01 100644
--- a/manifests/subsystems/database.pp
+++ b/manifests/subsystems/database.pp
@@ -13,9 +13,11 @@ class database {
require => Mysql_database["$name"],
}
- mysql_grant { "$name@%/$name":
- privileges => all,
- require => Mysql_user["$name@%"],
+ if $ensure == 'present' {
+ mysql_grant { "$name@%/$name":
+ privileges => all,
+ require => Mysql_user["$name@%"],
+ }
}
}
}