File tree Expand file tree Collapse file tree 4 files changed +10
-10
lines changed Expand file tree Collapse file tree 4 files changed +10
-10
lines changed Original file line number Diff line number Diff line change 1
1
---
2
2
- name : Ensure MySQL databases are present.
3
- mysql_db :
3
+ community.mysql. mysql_db :
4
4
name : " {{ item.name }}"
5
5
collation : " {{ item.collation | default('utf8_general_ci') }}"
6
6
encoding : " {{ item.encoding | default('utf8') }}"
Original file line number Diff line number Diff line change 1
1
---
2
2
- name : Ensure replication user exists on master.
3
- mysql_user :
3
+ community.mysql. mysql_user :
4
4
name : " {{ mysql_replication_user.name }}"
5
5
host : " {{ mysql_replication_user.host | default('%') }}"
6
6
login_unix_socket : " {{ login_unix_socket | default(omit) }}"
14
14
tags : ['skip_ansible_galaxy']
15
15
16
16
- name : Check slave replication status.
17
- mysql_replication :
17
+ community.mysql. mysql_replication :
18
18
mode : getslave
19
19
login_user : " {{ mysql_replication_user.name }}"
20
20
login_password : " {{ mysql_replication_user.password }}"
27
27
tags : ['skip_ansible_galaxy']
28
28
29
29
- name : Check master replication status.
30
- mysql_replication :
30
+ community.mysql. mysql_replication :
31
31
mode : getmaster
32
32
login_unix_socket : " {{ login_unix_socket | default(omit) }}"
33
33
delegate_to : " {{ mysql_replication_master }}"
39
39
tags : ['skip_ansible_galaxy']
40
40
41
41
- name : Configure replication on the slave.
42
- mysql_replication :
42
+ community.mysql. mysql_replication :
43
43
mode : changemaster
44
44
master_host : " {{ mysql_replication_master }}"
45
45
master_user : " {{ mysql_replication_user.name }}"
55
55
- (mysql_replication_master | length) > 0
56
56
57
57
- name : Start replication.
58
- mysql_replication :
58
+ community.mysql. mysql_replication :
59
59
mode : startslave
60
60
login_unix_socket : " {{ login_unix_socket | default(omit) }}"
61
61
when :
Original file line number Diff line number Diff line change 1
1
---
2
2
- name : Ensure default user is present.
3
- mysql_user :
3
+ community.mysql. mysql_user :
4
4
name : " {{ mysql_user_name }}"
5
5
host : ' localhost'
6
6
password : " {{ mysql_user_password }}"
77
77
check_mode : false
78
78
79
79
- name : Remove anonymous MySQL users.
80
- mysql_user :
80
+ community.mysql. mysql_user :
81
81
name : " "
82
82
host : " {{ item }}"
83
83
login_unix_socket : " {{ login_unix_socket | default(omit) }}"
84
84
state : absent
85
85
with_items : " {{ mysql_anonymous_hosts.stdout_lines|default([]) }}"
86
86
87
87
- name : Remove MySQL test database.
88
- mysql_db :
88
+ community.mysql. mysql_db :
89
89
name : " test"
90
90
login_unix_socket : " {{ login_unix_socket | default(omit) }}"
91
91
state : absent
Original file line number Diff line number Diff line change 1
1
---
2
2
- name : Ensure MySQL users are present.
3
- mysql_user :
3
+ community.mysql. mysql_user :
4
4
name : " {{ item.name }}"
5
5
host : " {{ item.host | default('localhost') }}"
6
6
password : " {{ item.password }}"
You can’t perform that action at this time.
0 commit comments