Skip to content

Commit

Permalink
fix key for privileges in the output to match mysql_user input
Browse files Browse the repository at this point in the history
  • Loading branch information
laurent-indermuehle committed Sep 20, 2023
1 parent 01eeed5 commit ed6b9c8
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions plugins/modules/mysql_info.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@
"name": "user1",
"host": "host.com",
"plugin": "mysql_native_password",
"privs": "'db1.*': 'SELECT'/'db2.*': 'SELECT'",
"priv": "'db1.*': 'SELECT'/'db2.*': 'SELECT'",
"resource_limits": { MAX_USER_CONNECTIONS: 100 } }
engines:
description: Information about the server's storage engines.
Expand Down Expand Up @@ -516,12 +516,12 @@ def __get_users_privs(self):
"users_privs": [
{
"host": "users_privs.com",
"privs": "*.*: ALL,GRANT",
"priv": "*.*: ALL,GRANT",
"user": "users_privs_adm"
},
{
"host": "users_privs.com",
"privs": "`mysql`.*: SELECT/`users_privs_db`.*: SELECT",
"priv": "`mysql`.*: SELECT/`users_privs_db`.*: SELECT",
"user": "users_privs_multi"
}
]
Expand Down Expand Up @@ -571,7 +571,7 @@ def __get_users_privs(self):
output_dict = {
'user': user,
'host': host,
'privs': '/'.join(priv_string),
'priv': '/'.join(priv_string),
'resource_limits': copy_ressource_limits,
}

Expand Down

0 comments on commit ed6b9c8

Please sign in to comment.