mirror of
https://github.com/ansible-collections/community.mysql.git
synced 2025-08-04 13:14:26 -07:00
Update plugins/module_utils/user.py
Co-authored-by: Andrew Klychkov <aaklychkov@mail.ru>
This commit is contained in:
parent
197b908c43
commit
8856f4d96e
1 changed files with 1 additions and 1 deletions
|
@ -171,7 +171,7 @@ def user_add(cursor, user, host, host_all, password, encrypted,
|
|||
query_with_args = "CREATE USER %s@%s IDENTIFIED WITH %s AS %s", (user, host, plugin, plugin_hash_string)
|
||||
elif plugin and plugin_auth_string:
|
||||
# Mysql and MariaDB differ in naming pam plugin and Syntax to set it
|
||||
if plugin == 'pam':
|
||||
if plugin == 'pam': # Used by MariaDB which requires the USING keyword, not BY
|
||||
query_with_args = "CREATE USER %s@%s IDENTIFIED WITH %s USING %s", (user, host, plugin, plugin_auth_string)
|
||||
else:
|
||||
query_with_args = "CREATE USER %s@%s IDENTIFIED WITH %s BY %s", (user, host, plugin, plugin_auth_string)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue