--- - name: php | installing php and modules apt: name: - php{{ php_version }}-fpm - php{{ php_version }}-common - php{{ php_version }}-cli - php{{ php_version }}-curl - php{{ php_version }}-opcache state: present notify: - restart php-fpm - name: php | install extra modules apt: name: '{{ php_modules | list }}' state: present force: yes notify: - restart php-fpm