Skip to content

Commit

Permalink
Add PHP 8 compatibility (#546)
Browse files Browse the repository at this point in the history
* Add PHP 8 compatibility

* Image over matrix version

* Use official elasticsearch docker registry

* Add missing version string for php 8 support

* Simplify workflow elasticsearch version and remove ignore platform reqs
  • Loading branch information
alexander-schranz authored Feb 23, 2021
1 parent de6290b commit 5ec1a53
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 18 deletions.
38 changes: 22 additions & 16 deletions .github/workflows/test-application.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
matrix:
include:
- php-version: '7.2'
elasticsearch-version: '5.6'
elasticsearch-version: '5.6.14'
elasticsearch-package-constraint: '~5.5'
phpcr-transport: doctrinedbal
dependency-versions: 'lowest'
Expand All @@ -30,12 +30,12 @@ jobs:
env:
SYMFONY_DEPRECATIONS_HELPER: disabled
PHPCR_TRANSPORT: doctrinedbal
ELASTICSEARCH_HOST: '127.0.0.1:9201'
ELASTICSEARCH_HOST: '127.0.0.1:9200'
DATABASE_CHARSET: UTF8
DATABASE_COLLATE: UTF8_BIN

- php-version: '7.4'
elasticsearch-version: '7.9'
elasticsearch-version: '7.9.3'
elasticsearch-package-constraint: '~7.9.0'
phpcr-transport: jackrabbit
dependency-versions: 'highest'
Expand All @@ -46,7 +46,21 @@ jobs:
env:
SYMFONY_DEPRECATIONS_HELPER: weak
PHPCR_TRANSPORT: jackrabbit
ELASTICSEARCH_HOST: '127.0.0.1:9202'
ELASTICSEARCH_HOST: '127.0.0.1:9200'

- php-version: '8.0'
elasticsearch-version: '7.11.1'
elasticsearch-package-constraint: '~7.11.0'
phpcr-transport: jackrabbit
dependency-versions: 'highest'
php-extensions: 'ctype, iconv, mysql, imagick'
tools: 'composer:v2'
phpstan: false
lint: false
env:
SYMFONY_DEPRECATIONS_HELPER: weak
PHPCR_TRANSPORT: jackrabbit
ELASTICSEARCH_HOST: '127.0.0.1:9200'

services:
mysql:
Expand All @@ -69,19 +83,10 @@ jobs:
ports:
- 8080:8080

elasticsearch5:
image: elasticsearch:5.6
ports:
- 9201:9200
env:
discovery.type: 'single-node'
xpack.security.enabled: 'false'
options: --health-cmd="curl http://localhost:9200/_cluster/health" --health-interval=10s --health-timeout=5s --health-retries=5

elasticsearch7:
image: elasticsearch:7.9.3
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:${{ matrix.elasticsearch-version }}
ports:
- 9202:9200
- 9200:9200
env:
discovery.type: 'single-node'
xpack.security.enabled: 'false'
Expand All @@ -106,6 +111,7 @@ jobs:
uses: ramsey/composer-install@v1
with:
dependency-versions: ${{matrix.dependency-versions}}
composer-options: ${{ matrix.composer-options }}

- name: Bootstrap test environment
run: composer bootstrap-test-environment
Expand Down
3 changes: 1 addition & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
}
],
"require": {
"php": "^7.2",
"php": "^7.2 || ^8.0",
"ext-json": "*",
"elasticsearch/elasticsearch": "^5.0 || ^6.0 || ^7.0",
"handcraftedinthealps/elasticsearch-bundle": "^5.2.6.4",
Expand All @@ -40,7 +40,6 @@
"jackalope/jackalope-doctrine-dbal": "^1.3.4",
"jackalope/jackalope-jackrabbit": "^1.3",
"massive/build-bundle": "^0.3 || ^0.4 || ^0.5",
"php-ffmpeg/php-ffmpeg": "^0.13 || ^0.14",
"phpcr/phpcr-shell": "^1.1",
"phpstan/phpstan": "^0.12.18",
"phpstan/phpstan-doctrine": "^0.12.9",
Expand Down

0 comments on commit 5ec1a53

Please sign in to comment.