forked from evolix/ansible-roles
Add support for PHP 7.1 using sury repository.
See the documentation: https://wiki.evolix.org/HowtoPHP#php-7.1-avec-deb.sury.org
This commit is contained in:
parent
c430fa3485
commit
fa55761714
|
@ -1,5 +1,6 @@
|
|||
---
|
||||
|
||||
php_sury_enable: False
|
||||
php_fpm_enable: False
|
||||
php_apache_enable: False
|
||||
php_symfony_requirements: False
|
||||
|
|
|
@ -3,3 +3,7 @@
|
|||
service:
|
||||
name: php-fpm
|
||||
state: restarted
|
||||
|
||||
- name: apt update
|
||||
apt:
|
||||
update_cache: yes
|
||||
|
|
|
@ -8,6 +8,9 @@
|
|||
- include: php_jessie.yml
|
||||
when: ansible_distribution_release == "jessie"
|
||||
|
||||
- include: php_stretch_sury.yml
|
||||
when: ansible_distribution_major_version | version_compare('9', '>=') and php_sury_enable
|
||||
|
||||
- include: php_stretch.yml
|
||||
when: ansible_distribution_major_version | version_compare('9', '>=')
|
||||
|
||||
|
|
24
php/tasks/php_stretch_sury.yml
Normal file
24
php/tasks/php_stretch_sury.yml
Normal file
|
@ -0,0 +1,24 @@
|
|||
---
|
||||
|
||||
- name: Setup deb.sury.org repository - Add GPG key
|
||||
get_url:
|
||||
url: https://packages.sury.org/php/apt.gpg
|
||||
dest: /etc/apt/trusted.gpg.d/php71-sury.gpg
|
||||
mode: "0644"
|
||||
|
||||
- name: Setup deb.sury.org repository - Install apt-transport-https
|
||||
apt:
|
||||
state: present
|
||||
name: apt-transport-https
|
||||
|
||||
- name: Setup deb.sury.org repository - Add source list
|
||||
copy:
|
||||
dest: /etc/apt/sources.list.d/php71-sury.list
|
||||
force: no
|
||||
mode: "0600"
|
||||
content: |
|
||||
deb https://packages.sury.org/php/ stretch main
|
||||
notify: apt update
|
||||
|
||||
- name: Intermediate flush of handlers
|
||||
meta: flush_handlers
|
Loading…
Reference in a new issue