ansible-php/tasks/xdebug.yml

43 lines
950 B
YAML

---
- block:
- name: APT | Install xdebug
apt:
pkg: "{{ php_xdebug_package }}"
state: present
update_cache: yes
cache_valid_time: 3600
when: ansible_os_family == 'Debian'
- name: PKGNG | Install xdebug
pkgng:
name: "{{ php_xdebug_package }}"
when: ansible_os_family == 'FreeBSD' and php_xdebug_package is defined
- name: TEMPLATE | Deploy module configurations
template:
src: "etc/__php__/mods-available/xdebug.ini.j2"
dest: "{{ php_mods_dir }}/xdebug.ini"
owner: root
mode: 0644
notify: restart php-fpm
when: php_install_xdebug
- block:
- name: APT | Uninstall xdebug
apt:
pkg: "{{ php_xdebug_package }}"
state: absent
when: ansible_os_family == 'Debian'
- name: PKGNG | Uninstall xdebug
pkgng:
name: "{{ php_xdebug_package }}"
state: absent
when: ansible_os_family == 'FreeBSD'
when: not php_install_xdebug