Looks like this has been fixed for later versions of Ansible, however
version 2.9.X ships with Ubuntu focal and groovy. (The LTS release focal
will still be around for some time.)

Adding a patch to mirror the following code (along with the function
impl.supports_identified_by_password() )

    if password and encrypted:
        if impl.supports_identified_by_password(cursor):
            query_with_args = "CREATE USER %s@%s IDENTIFIED BY PASSWORD %s", 
(user, host, password)
        else:
            query_with_args = "CREATE USER %s@%s IDENTIFIED WITH 
mysql_native_password AS %s", (user, host, password)


would certainly help.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1923077

Title:
  Ansible module with mysql_user fails to create new user, if option
  encrypted is set

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ansible/+bug/1923077/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to