2022-02-10 15:23:07 +01:00

57 lines
1.1 KiB
YAML

- name: apt update
tags: update
apt:
update-cache: yes
cache_valid_time: 3600
- name: installation des utilitaires
tags: utils
apt:
name:
- apache2
- php
- php-common
- libapache2-mod-php
- php-cli
- php-xml
- php-mysql
- php-curl
- mariadb-server
- adminer
- python3-pymysql
state: present
- name: Create a symbolic link
ansible.builtin.file:
src: /usr/share/adminer/adminer
dest: /var/www/html/adminer
# owner:
# group:
state: link
- name: Message d'information
tags: msg
debug: msg="Adminer sera accessible depuis l'adresse http://onfarbo44/adminer/"
- name: On démarre MariaDB
tags: mariadb
service:
name: mysql
state: started
- name: Création de la BDD bdarbre
tags: bdarbre
mysql_db:
login_unix_socket: /var/run/mysqld/mysqld.sock
name: bdarbre
- name: Création de l'utilisateur slam
tags: user
mysql_user:
name: slam
password: Azerty1+
priv: '*.*:ALL,GRANT'
state: present
login_unix_socket: /var/run/mysqld/mysqld.sock
notify: restart apache