Skip to content

Commit 1b6e945

Browse files
authored
Create ci.yml
1 parent ac563b8 commit 1b6e945

File tree

1 file changed

+46
-0
lines changed

1 file changed

+46
-0
lines changed

.github/workflows/ci.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Package CI
2+
3+
on:
4+
pull_request:
5+
6+
jobs:
7+
checks:
8+
name: Checks
9+
runs-on: ubuntu-latest
10+
strategy:
11+
matrix:
12+
php: [ 7.4 ]
13+
elastic: [ 7.12.1, 6.8.15, 5.6.16 ]
14+
15+
steps:
16+
- uses: actions/checkout@v2
17+
- uses: shivammathur/setup-php@v2
18+
with:
19+
php-version: ${{ matrix.php }}
20+
21+
- name: Configure sysctl limits
22+
run: |
23+
sudo swapoff -a
24+
sudo sysctl -w vm.swappiness=1
25+
sudo sysctl -w fs.file-max=262144
26+
sudo sysctl -w vm.max_map_count=262144
27+
28+
- name: Start Elasticsearch
29+
uses: elastic/elastic-github-actions/elasticsearch@master
30+
with:
31+
stack-version: ${{ matrix.elastic }}
32+
33+
- name: Composer
34+
run: make composer
35+
36+
- if: matrix.php == '7.4' && matrix.elastic == "7.12.1"
37+
name: Coding standard
38+
run: make cs
39+
40+
- if: matrix.php == '7.4' && matrix.elastic == "7.12.1"
41+
name: PHPStan
42+
run: make phpstan
43+
44+
- if: matrix.php == '7.4'
45+
name: Tests
46+
run: make tests

0 commit comments

Comments
 (0)