mirror of
https://github.com/aljazceru/ansible-role-mysql.git
synced 2025-12-19 03:34:21 +01:00
Merge branch 'master' of git://github.com/dsglaser/ansible-role-mysql into dglaser-master
This commit is contained in:
@@ -33,6 +33,19 @@
|
||||
shell: "touch {{ mysql_slow_query_log_file }} creates={{ mysql_slow_query_log_file }}"
|
||||
when: mysql_slow_query_log_enabled
|
||||
|
||||
- name: Create datadir if it does not exist
|
||||
file:
|
||||
path: "{{ mysql_datadir }}"
|
||||
state: directory
|
||||
owner: mysql
|
||||
group: mysql
|
||||
mode: 0755
|
||||
|
||||
- name: Set selinux context on datadir
|
||||
file:
|
||||
path: "{{ mysql_datadir }}"
|
||||
setype: mysqld_db_t
|
||||
|
||||
- name: Set ownership on slow query log file (if configured).
|
||||
file:
|
||||
path: "{{ mysql_slow_query_log_file }}"
|
||||
|
||||
@@ -2,6 +2,17 @@
|
||||
# Include variables and define needed variables.
|
||||
- name: Include OS-specific variables.
|
||||
include_vars: "{{ ansible_os_family }}.yml"
|
||||
when: ansible_os_family != "RedHat"
|
||||
|
||||
# Include RedHat 6 variables (mysql)
|
||||
- name: Include OS-specific variables.
|
||||
include_vars: "{{ ansible_os_family }}-{{ ansible_lsb.major_release }}.yml"
|
||||
when: ansible_lsb.major_release < "7"
|
||||
|
||||
# Include RedHat 7 variables (mariadb)
|
||||
- name: Include OS-specific variables.
|
||||
include_vars: "{{ ansible_os_family }}-{{ ansible_lsb.major_release }}.yml"
|
||||
when: ansible_os_family >= "7"
|
||||
|
||||
- name: Define mysql_packages.
|
||||
set_fact:
|
||||
|
||||
Reference in New Issue
Block a user