Blog_IMIE/ops/ansible/mariadb-debian.yml
2018-10-31 15:59:52 +01:00

26 lines
490 B
YAML

---
- hosts: hifive
become: yes
become_user: root
tasks:
- name: install mariadb
apt:
pkg:
- mariadb-server
- mariadb-client
- mariadb-common
- python-mysqldb
state: present
- name: Create a new user bob
mysql_user:
name: bob
password: bob
priv: '*.*:ALL'
state: present
- name: Create a new database bobdata
mysql_db:
name: bobdata
state: present