ansible-mysql/tasks/replication/slave/debiancnf.yml

26 lines
636 B
YAML

---
- name: FETCH | Get /etc/mysql/debian.cnf on master
fetch:
src: /etc/mysql/debian.cnf
dest: /tmp/{{ mariadb_slave_import_from }}/debian.cnf
flat: yes
changed_when: false
delegate_to: "{{ mariadb_slave_import_from }}"
- name: LOCAL_ACTION FILE | Secure fetched file
local_action:
module: file
path: "/tmp/{{ mariadb_slave_import_from }}/debian.cnf"
mode: 0600
become: no
- name: COPY | Fetched file to /etc/mysql/debian.cnf
copy:
src: "/tmp/{{ mariadb_slave_import_from }}/debian.cnf"
dest: /etc/mysql/debian.cnf
owner: root
group: root
mode: 0600
notify: restart mariadb