Geerlingguy.mysql failing with empty value

Hi

I’m trying to install latest version of mysql using geerlingguy.mysql role on an ubuntu vm(Version 22.04). Would like to install the mysql-server package instead of MariaDB package.
The role fails with error below

Empty hostname produced from delegate_to: {{ mysql_replication_master_inventory_host }}

This is my variables file

mysql_databases:
  - name: "{{ database }}"
    state: present
mysql_users:
  - name: "{{ name }}"
    password: "{{ password }}"
    priv: "{{ name }}.*:ALL"
    state: present

I’ve not defined replication, so not sure why its checking the replication master
Can someone help in pointing out if I’m doing something wrong/missing here

Thanks in advance!

playbook role mysql galaxy

Your question is likely better suited to be asked in Jeff’s role repository.

Thanks a lot for the response. I’ve posted an issue in geerlingguy repository.
(And I think the issue is related to ansible core 2.16. I get it working using awx)

BTW, if you include the link to the issue/discussion/… in the role repository, others who find this discussion first can quickly navigate to the other discussion :slight_smile:

Are you sure you’re using the latest version of the role? This error should have been fixed by Workaround for https://github.com/ansible/ansible/issues/82264 · geerlingguy/ansible-role-mysql@b04a0ca · GitHub, which is included in the 4.3.4 release.

1 Like

Sure, Below is the link of the issue posted.

Aah sorry my bad
And yes it worked :slight_smile: . I was using the 4.3.3 version locally and thus faced this issue. But in awx, I was specifying the version 4.3.4 in the requirements.yml file and thus it worked there.
Thanks a lot for all your help and inputs :+1:

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.