From 7ea6036859ba2a36e2bc148258985b94592851d2 Mon Sep 17 00:00:00 2001 From: Jeff Geerling Date: Thu, 18 Mar 2021 16:33:55 -0500 Subject: [PATCH] Deprecate PHP 7.2 support and add warnings about using it. --- .github/workflows/ci.yml | 16 +++++----------- README.md | 6 +++--- defaults/main.yml | 2 +- molecule/default/{7.2.yml => 7.3.yml} | 2 +- molecule/default/7.4.yml | 24 ------------------------ tasks/setup-RedHat.yml | 2 ++ vars/Debian.yml | 2 ++ 7 files changed, 14 insertions(+), 40 deletions(-) rename molecule/default/{7.2.yml => 7.3.yml} (95%) delete mode 100644 molecule/default/7.4.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index cdb9496..24f8d52 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -41,7 +41,7 @@ jobs: strategy: matrix: include: - # Default PHP version (7.3). + # Default PHP version (7.4). - distro: centos8 playbook: converge.yml - distro: centos7 @@ -59,19 +59,13 @@ jobs: - distro: debian10 playbook: 8.0.yml - # PHP 7.4. + # PHP 7.3. - distro: centos8 - playbook: 7.4.yml + playbook: 7.3.yml - distro: ubuntu1804 - playbook: 7.4.yml + playbook: 7.3.yml - distro: debian10 - playbook: 7.4.yml - - # PHP 7.2. - - distro: centos8 - playbook: 7.2.yml - - distro: ubuntu1804 - playbook: 7.2.yml + playbook: 7.3.yml steps: - name: Check out the codebase. diff --git a/README.md b/README.md index 424fe40..45274e4 100644 --- a/README.md +++ b/README.md @@ -12,9 +12,9 @@ N/A Available variables are listed below, along with default values (see `defaults/main.yml`): - php_version: '7.3' + php_version: '7.4' -The PHP version to be installed. Any [currently-supported PHP major version](http://php.net/supported-versions.php) is a valid option (e.g. `7.2`, `7.3`, `7.4` etc.). +The PHP version to be installed. Any [currently-supported PHP major version](http://php.net/supported-versions.php) is a valid option (e.g. `7.3`, `7.4`, or `8.0`). php_versions_install_recommends: false @@ -31,7 +31,7 @@ The PHP version to be installed. Any [currently-supported PHP major version](htt become: true vars: - php_version: '7.3' + php_version: '7.4' roles: - name: geerlingguy.repo-remi diff --git a/defaults/main.yml b/defaults/main.yml index 289b1ba..14647c0 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -1,6 +1,6 @@ --- # The PHP version to be installed. -php_version: '7.3' +php_version: '7.4' # For Debian OSes only. php_versions_install_recommends: false diff --git a/molecule/default/7.2.yml b/molecule/default/7.3.yml similarity index 95% rename from molecule/default/7.2.yml rename to molecule/default/7.3.yml index 6ae3076..e6e55ca 100644 --- a/molecule/default/7.2.yml +++ b/molecule/default/7.3.yml @@ -5,7 +5,7 @@ vars: php_enable_webserver: false - php_version: '7.2' + php_version: '7.3' pre_tasks: - name: Update apt cache. diff --git a/molecule/default/7.4.yml b/molecule/default/7.4.yml deleted file mode 100644 index f42e564..0000000 --- a/molecule/default/7.4.yml +++ /dev/null @@ -1,24 +0,0 @@ ---- -- name: Converge - hosts: all - become: true - - vars: - php_enable_webserver: false - php_version: '7.4' - - pre_tasks: - - name: Update apt cache. - apt: update_cache=true cache_valid_time=600 - when: ansible_os_family == 'Debian' - - roles: - - role: geerlingguy.repo-remi - when: ansible_os_family == 'RedHat' - - role: geerlingguy.php-versions - - role: geerlingguy.php - - post_tasks: - - name: Confirm PHP version is correct. - shell: php -v | grep -F '{{ php_version }}' - changed_when: false diff --git a/tasks/setup-RedHat.yml b/tasks/setup-RedHat.yml index d281613..c20f002 100644 --- a/tasks/setup-RedHat.yml +++ b/tasks/setup-RedHat.yml @@ -1,4 +1,6 @@ --- +# TODO: PHP 7.2 support will be removed soon. This is only being left in here as +# a convenience for legacy PHP 7.2 users. - name: Enable remi repo for PHP 7.2. set_fact: php_enablerepo="remi,remi-php72" when: php_version == "7.2" diff --git a/vars/Debian.yml b/vars/Debian.yml index 769766c..bcaee60 100644 --- a/vars/Debian.yml +++ b/vars/Debian.yml @@ -39,6 +39,8 @@ __php_packages: - "php{{ php_version }}-yaml" php_versions_debian: + # TODO: PHP 7.2 support will be removed soon. This is only being left in here as + # a convenience for legacy PHP 7.2 users. - php7.2-common - php7.3-common - php7.4-common