Skip to content

Commit c7759eb

Browse files
authored
Merge pull request geerlingguy#214 from ikelos/issue-146
Allow replication against masters without a .my.conf file.
2 parents 259cc2d + 64bbe25 commit c7759eb

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

tasks/replication.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,18 @@
44
name: "{{ mysql_replication_user.name }}"
55
host: "{{ mysql_replication_user.host | default('%') }}"
66
password: "{{ mysql_replication_user.password }}"
7-
priv: "{{ mysql_replication_user.priv | default('*.*:REPLICATION SLAVE') }}"
7+
priv: "{{ mysql_replication_user.priv | default('*.*:REPLICATION SLAVE,REPLICATION CLIENT') }}"
88
state: present
99
when: >
1010
(mysql_replication_role == 'master')
1111
and mysql_replication_user
1212
and (mysql_replication_master != '')
1313
1414
- name: Check slave replication status.
15-
mysql_replication: mode=getslave
15+
mysql_replication:
16+
mode: getslave
17+
login_user: "{{ mysql_replication_user.name }}"
18+
login_password: "{{ mysql_replication_user.password }}"
1619
ignore_errors: true
1720
register: slave
1821
when: >

0 commit comments

Comments
 (0)