mirror of
https://github.com/geerlingguy/ansible-role-apache
synced 2025-01-10 20:00:18 +01:00
21 lines
532 B
YAML
21 lines
532 B
YAML
---
|
|
- name: Copy my.cnf global MySQL configuration.
|
|
template:
|
|
src: my.cnf.j2
|
|
dest: "{{ mysql_config_file }}"
|
|
owner: root
|
|
group: root
|
|
mode: 0644
|
|
notify: restart mysql
|
|
|
|
- name: Ensure MySQL is started and enabled on boot.
|
|
service: "name={{ mysql_daemon }} state=started enabled={{ mysql_enabled_on_startup }}"
|
|
|
|
- name: Ensure MySQL socket file has correct permissions.
|
|
file:
|
|
path: "{{ item }}"
|
|
mode: 0755
|
|
notify: restart mysql
|
|
with_items:
|
|
- "{{ mysql_datadir }}"
|
|
- "{{ mysql_socket }}"
|