2021-12-13 17:09:50 +01:00

40 lines
702 B
YAML

- name: "[MYSQL] - update cache"
apt:
update_cache: yes
- name: "[MYSQL] - install"
apt:
name: mariadb-server
state: latest
- name: "[Python] - install"
apt:
name: python
state: latest
- name: "[MYSQL] - start mysql"
service:
name: "mysqld"
state: started
enabled: yes
- name: "[MYSQL] - create database"
community.mysql.mysql_db:
name:
- sdis29
state: present
- name: "[MYSQL] - create user"
mysql_user:
name: "dev"
password: "Azerty1+"
priv: "*.*:ALL"
host: "127.0.0.1"
become: yes
- name: Restoration la base de données
community.mysql.mysql_db:
name: my_db
state: import
target: /tmp/db-sauv.sql.gz