Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 13 additions & 5 deletions .github/workflows/plugin-ci-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ on:
branches:
- main
- develop
env:
CACTI: 1.2.x

jobs:
integration-test:
Expand All @@ -38,7 +40,7 @@ jobs:
strategy:
fail-fast: false
matrix:
php: ['8.1', '8.2', '8.3', '8.4']
php: ['8.2', '8.3', '8.4']
os: [ubuntu-latest]

services:
Expand All @@ -64,6 +66,7 @@ jobs:
uses: actions/checkout@v4
with:
repository: Cacti/cacti
ref: ${{ env.CACTI }}
path: cacti

- name: Checkout servcheck Plugin
Expand All @@ -85,7 +88,7 @@ jobs:
run: sudo apt-get update

- name: Install System Dependencies
run: sudo apt-get install -y apache2 snmp snmpd rrdtool fping libapache2-mod-php${{ matrix.php }}
run: sudo apt-get install -y snmp snmpd rrdtool fping

- name: Start SNMPD Agent and Test
run: |
Expand Down Expand Up @@ -179,23 +182,28 @@ jobs:
fi

- name: Remove the plugins directory exclusion from the .phpstan.neon
if: ${{ env.CACTI != '1.2.x' }}
run: sed '/plugins/d' -i .phpstan.neon
working-directory: ${{ github.workspace }}/cacti

- name: Mark composer scripts executable
if: ${{ env.CACTI != '1.2.x' }}
run: sudo chmod +x ${{ github.workspace }}/cacti/include/vendor/bin/*

- name: Run Linter on base code
if: ${{ env.CACTI != '1.2.x' }}
run: composer run-script lint ${{ github.workspace }}/cacti/plugins/servcheck
working-directory: ${{ github.workspace }}/cacti

- name: Checking coding standards on base code
if: ${{ env.CACTI != '1.2.x' }}
run: composer run-script phpcsfixer ${{ github.workspace }}/cacti/plugins/servcheck
working-directory: ${{ github.workspace }}/cacti

# - name: Run PHPStan at Level 6 on base code outside of Composer due to technical issues
# run: ./include/vendor/bin/phpstan analyze --level 6 ${{ github.workspace }}/cacti/plugins/servcheck
# working-directory: ${{ github.workspace }}/cacti
- name: Run PHPStan at Level 6 on base code outside of Composer due to technical issues
if: ${{ env.CACTI != '1.2.x' }}
run: ./include/vendor/bin/phpstan analyze --level 6 ${{ github.workspace }}/cacti/plugins/servcheck
working-directory: ${{ github.workspace }}/cacti

- name: Run Cacti Poller
run: |
Expand Down
Loading