mirror of
https://github.com/e107inc/e107.git
synced 2025-07-26 01:11:28 +02:00
Issue #5443 Use PHP 8.1
This commit is contained in:
21
.github/workflows/test-acceptance.yml
vendored
21
.github/workflows/test-acceptance.yml
vendored
@@ -9,12 +9,8 @@ jobs:
|
|||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
php_version:
|
|
||||||
- "8.0" # Test with PHP 8.0
|
|
||||||
# Uncomment the line below to also test with PHP 8.4
|
|
||||||
# - "8.4"
|
|
||||||
operating_system:
|
operating_system:
|
||||||
- image: docker.io/jrei/systemd-ubuntu:20.04 # Base image with PHP 8.0
|
- image: docker.io/jrei/systemd-ubuntu:22.04 # Uses PHP 8.1 by default
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
@@ -51,22 +47,15 @@ jobs:
|
|||||||
"
|
"
|
||||||
working-directory: ./e107_tests/lib/ci/salt/
|
working-directory: ./e107_tests/lib/ci/salt/
|
||||||
|
|
||||||
- name: Install PHP and extensions
|
- name: Install PHP extensions
|
||||||
run: |
|
run: |
|
||||||
docker exec target apt-get update
|
docker exec target apt-get update
|
||||||
docker exec target apt-get install -y software-properties-common
|
docker exec target apt-get install -y php8.1-zip php8.1-curl php8.1-mbstring php8.1-xml
|
||||||
# Add ondrej/php PPA for PHP 8.4 support (optional)
|
# Install extensions for PHP 8.1 (default in Ubuntu 22.04)
|
||||||
docker exec target add-apt-repository ppa:ondrej/php -y
|
|
||||||
docker exec target apt-get update
|
|
||||||
# Install PHP and required extensions
|
|
||||||
docker exec target apt-get install -y php${{ matrix.php_version }} php${{ matrix.php_version }}-zip php${{ matrix.php_version }}-curl php${{ matrix.php_version }}-mbstring php${{ matrix.php_version }}-xml
|
|
||||||
# Set the specified PHP version as the default
|
|
||||||
docker exec target update-alternatives --set php /usr/bin/php${{ matrix.php_version }}
|
|
||||||
# Note: For PHP 8.0 on Ubuntu 20.04, this step will essentially ensure the default version is used and extensions are installed.
|
|
||||||
|
|
||||||
- name: Verify PHP version
|
- name: Verify PHP version
|
||||||
run: docker exec target php -v
|
run: docker exec target php -v
|
||||||
# This step helps confirm the PHP version in use.
|
# Confirms PHP 8.1 is in use
|
||||||
|
|
||||||
- name: Install test dependencies
|
- name: Install test dependencies
|
||||||
run: |
|
run: |
|
||||||
|
Reference in New Issue
Block a user