From 9ec6fbf952e4c9a1d71f3efd9e9487474d6264fc Mon Sep 17 00:00:00 2001 From: Emilien Mantel Date: Sat, 27 Feb 2016 13:05:02 +0100 Subject: [PATCH] Install Opcache only on PHP >= 7.0 --- tasks/opcache.yml | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/tasks/opcache.yml b/tasks/opcache.yml index 42f1f9a..ef5e657 100644 --- a/tasks/opcache.yml +++ b/tasks/opcache.yml @@ -1,10 +1,11 @@ --- -- name: APT | Install APCu / Opcache - apt: pkg={{ item }} state=latest - with_items: - - "{{ php_apt_prefix }}apcu" - - "{{ php_apt_prefix }}opcache" +- name: APT | Install APCu + apt: pkg="{{ php_apt_prefix }}apcu" state=present + +- name: APT | Install Opcache + apt: pkg="{{ php_apt_prefix }}opcache" state=present + when: php_version | version_compare('7.0', 'ge') - name: TEMPLATE | Configure APCu template: >