--- /dev/null
+- name: Etckeeper commit if necessary
+ ansible.builtin.command: etckeeper commit "commit by ansible because installing {{ DOMAIN }}/{{ SITE }}"
+
+- name: Install required packages
+ ansible.builtin.apt:
+ name:
+ - ghostscript
+ - php
+ - php-mysqli
+ - php-curl
+# - php-dom
+ - php-exif
+ - php-igbinary
+ - php-mbstring
+ - imagemagick
+ - php-imagick
+ - php-intl
+ - php-openssl
+ - libxml
+ - php-xml
+ - libzip
+ - php-zip
+ - php-redis
+ state: present
+ register: php_install
+
+- name: Enable PHP modules
+ ansible.builtin.command: phpenmod imagick intl
+ when: php_install.changed
+
+
+- name: Recharger PHP et nginx
+ ansible.builtin.service:
+ name: "{{ item }}"
+ state: reloaded
+ loop:
+ - "php{{ php_version }}-fpm"
+ - "nginx"