From 0379abc36cd3d0a283ae514ff3b95cc1b790e7de Mon Sep 17 00:00:00 2001 From: Michael Scherer Date: Fri, 12 Dec 2014 15:55:58 +0100 Subject: Add mariadb module --- roles/mariadb/handlers/main.yml | 3 +++ roles/mariadb/tasks/main.yml | 9 +++++++++ roles/mariadb/templates/custom.cnf | 3 +++ 3 files changed, 15 insertions(+) create mode 100644 roles/mariadb/handlers/main.yml create mode 100644 roles/mariadb/tasks/main.yml create mode 100644 roles/mariadb/templates/custom.cnf (limited to 'roles') diff --git a/roles/mariadb/handlers/main.yml b/roles/mariadb/handlers/main.yml new file mode 100644 index 0000000..6f737d9 --- /dev/null +++ b/roles/mariadb/handlers/main.yml @@ -0,0 +1,3 @@ +--- +- name: restart mariadb + service: name=mariadb state=restarted diff --git a/roles/mariadb/tasks/main.yml b/roles/mariadb/tasks/main.yml new file mode 100644 index 0000000..10783bb --- /dev/null +++ b/roles/mariadb/tasks/main.yml @@ -0,0 +1,9 @@ +--- +- yum: name={{ item }} state=installed + with_items: + - mariadb-server + +- template: src=custom.cnf dest=/etc/my.cnf.d/custom.cnf + notify: restart mariadb + +- service: name=mariadb enabled=yes state=started diff --git a/roles/mariadb/templates/custom.cnf b/roles/mariadb/templates/custom.cnf new file mode 100644 index 0000000..258f81e --- /dev/null +++ b/roles/mariadb/templates/custom.cnf @@ -0,0 +1,3 @@ +[mysqld] +bind-address = 127.0.0.1 + -- cgit