Merge pull request #4352 from jhoekx/mysql-user-grant

Add grant parameter to MySQL user module
This commit is contained in:
Michael DeHaan
2013-10-07 06:08:39 -07:00
2 changed files with 15 additions and 5 deletions

View File

@@ -52,7 +52,7 @@ Nested Loops
Loops can be nested as well::
- name: give users access to multiple databases
mysql_user: name={{ item[0] }} priv={{ item[1] }}.*:ALL password=foo
mysql_user: name={{ item[0] }} priv={{ item[1] }}.*:ALL append_privs=yes password=foo
with_nested:
- [ 'alice', 'bob', 'eve' ]
- [ 'clientdb', 'employeedb', 'providerdb' ]
@@ -60,7 +60,7 @@ Loops can be nested as well::
As with the case of 'with_items' above, you can use previously defined variables. Just specify the variable's name without templating it with '{{ }}'::
- name: here, 'users' contains the above list of employees
mysql_user: name={{ item[0] }} priv={{ item[1] }}.*:ALL password=foo
mysql_user: name={{ item[0] }} priv={{ item[1] }}.*:ALL append_privs=yes password=foo
with_nested:
- users
- [ 'clientdb', 'employeedb', 'providerdb' ]