mirror of
https://github.com/geerlingguy/ansible-role-apache
synced 2025-01-10 20:00:18 +01:00
21 lines
560 B
YAML
21 lines
560 B
YAML
---
|
|
# This playbook will install MariaDB and create db user and give permissions.
|
|
|
|
- name: Install MariaDB package
|
|
yum: name={{ item }} state=installed
|
|
with_items:
|
|
- mariadb-server
|
|
- MySQL-python
|
|
- libselinux-python
|
|
- libsemanage-python
|
|
|
|
- name: Create Mysql configuration file
|
|
template: src=my.cnf.j2 dest=/etc/my.cnf
|
|
notify:
|
|
- restart mariadb
|
|
|
|
- name: Create MariaDB log file
|
|
file: path=/var/log/mysqld.log state=touch owner=mysql group=mysql mode=0775
|
|
|
|
- name: Start MariaDB Service
|
|
service: name=mariadb state=started enabled=yes
|