@@ -14,13 +14,13 @@ jobs:
1414 runs-on : ubuntu-latest
1515 container : joomlaprojects/docker-images:php8.4
1616 steps :
17- - uses : actions/checkout@v6
18- - uses : actions/cache@v5
17+ - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
18+ - uses : actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
1919 id : cache-php
2020 with :
2121 path : libraries/vendor
2222 key : ${{ runner.os }}-composer-${{ hashFiles('composer.lock') }}
23- - uses : actions/cache@v4
23+ - uses : actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
2424 id : cache-webauthn
2525 with :
2626 path : plugins/system/webauthn/fido.jwt
@@ -39,11 +39,11 @@ jobs:
3939 container : joomlaprojects/docker-images:php8.4
4040 needs : [composer]
4141 steps :
42- - uses : actions/setup-node@v6
42+ - uses : actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
4343 with :
4444 node-version : latest
45- - uses : actions/checkout@v6
46- - uses : actions/cache@v5
45+ - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
46+ - uses : actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
4747 id : cache-assets
4848 with :
4949 path : |
@@ -54,17 +54,17 @@ jobs:
5454 installation/template/js
5555 installation/template/scss
5656 key : ${{ runner.os }}-node-${{ hashFiles('package-lock.json', 'build/build.mjs', 'build/build-modules-js/**', 'media_source/**') }}
57- - uses : actions/cache/restore@v5
57+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
5858 with :
5959 path : libraries/vendor
6060 key : ${{ runner.os }}-composer-${{ hashFiles('composer.lock') }}
61- - uses : actions/cache/restore@v4
61+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
6262 with :
6363 path : plugins/system/webauthn/fido.jwt
6464 key : ${{ runner.os }}-webauthn-${{ hashFiles('composer.lock') }}
6565 - name : Build assets
6666 if : steps.cache-assets.outputs.cache-hit != 'true'
67- run : npm ci --unsafe-perm
67+ run : npm ci
6868
6969 code-style-php :
7070 name : Check PHP code style
@@ -75,12 +75,12 @@ jobs:
7575 matrix :
7676 command : ['php-cs-fixer fix -vvv --dry-run --diff', 'phpcs --extensions=php -p --standard=ruleset.xml .']
7777 steps :
78- - uses : actions/checkout@v6
79- - uses : actions/cache/restore@v5
78+ - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
79+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
8080 with :
8181 path : libraries/vendor
8282 key : ${{ runner.os }}-composer-${{ hashFiles('composer.lock') }}
83- - uses : actions/cache/restore@v4
83+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
8484 with :
8585 path : plugins/system/webauthn/fido.jwt
8686 key : ${{ runner.os }}-webauthn-${{ hashFiles('composer.lock') }}
@@ -98,11 +98,11 @@ jobs:
9898 matrix :
9999 check : ['lint:js', 'lint:testjs', 'lint:css']
100100 steps :
101- - uses : actions/setup-node@v6
101+ - uses : actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
102102 with :
103103 node-version : latest
104- - uses : actions/checkout@v6
105- - uses : actions/cache/restore@v5
104+ - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
105+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
106106 with :
107107 path : |
108108 node_modules
@@ -121,18 +121,28 @@ jobs:
121121 container : joomlaprojects/docker-images:php8.4
122122 needs : [code-style-php]
123123 steps :
124- - uses : actions/checkout@v6
125- - uses : actions/cache/restore@v5
124+ - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
125+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
126126 with :
127127 path : libraries/vendor
128128 key : ${{ runner.os }}-composer-${{ hashFiles('composer.lock') }}
129- - uses : actions/cache/restore@v4
129+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
130130 with :
131131 path : plugins/system/webauthn/fido.jwt
132132 key : ${{ runner.os }}-webauthn-${{ hashFiles('composer.lock') }}
133133 - name : Run PHPstan
134134 run : |
135+ set -e
135136 ./libraries/vendor/bin/phpstan --error-format=github
137+ ./libraries/vendor/bin/phpstan --generate-baseline
138+ git config --global --add safe.directory "$GITHUB_WORKSPACE"
139+ if [ "$GITHUB_EVENT_NAME" = "push" ] && [ "$GITHUB_REPOSITORY" != "joomla/joomla-cms" ] && ! git diff --quiet -- phpstan-baseline.neon; then
140+ git config user.name "github-actions[bot]"
141+ git config user.email "github-actions[bot]@users.noreply.github.com"
142+ git add phpstan-baseline.neon
143+ git commit -m "Updated PHPStan baseline [skip ci]"
144+ git push origin "HEAD:${{ github.head_ref || github.ref_name }}"
145+ fi
136146
137147 tests-unit :
138148 name : Run Unit tests
@@ -143,12 +153,12 @@ jobs:
143153 matrix :
144154 php_version : ['8.3', '8.4', '8.5']
145155 steps :
146- - uses : actions/checkout@v6
147- - uses : actions/cache/restore@v5
156+ - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
157+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
148158 with :
149159 path : libraries/vendor
150160 key : ${{ runner.os }}-composer-${{ hashFiles('composer.lock') }}
151- - uses : actions/cache/restore@v4
161+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
152162 with :
153163 path : plugins/system/webauthn/fido.jwt
154164 key : ${{ runner.os }}-webauthn-${{ hashFiles('composer.lock') }}
@@ -189,16 +199,16 @@ jobs:
189199 host : ' postgres'
190200 user : ' root'
191201 steps :
192- - uses : actions/checkout@v6
202+ - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
193203 - name : Start LDAP container
194204 uses : docker://docker
195205 with :
196206 args : docker run -d --name openldap --network ${{ job.container.network }} --network-alias openldap -e "LDAP_ADMIN_USERNAME=admin" -e "LDAP_ADMIN_PASSWORD=adminpassword" -e "LDAP_USERS=customuser" -e "LDAP_PASSWORDS=custompassword" -e "LDAP_ENABLE_TLS=yes" -e "LDAP_TLS_CERT_FILE=/certs/openldap.crt" -e "LDAP_TLS_KEY_FILE=/certs/openldap.key" -e "LDAP_TLS_CA_FILE=/certs/CA.crt" -e "BITNAMI_DEBUG=true" -e "LDAP_CONFIG_ADMIN_ENABLED=yes" -e "LDAP_CONFIG_ADMIN_USERNAME=admin" -e "LDAP_CONFIG_ADMIN_PASSWORD=configpassword" -v "${{ github.workspace }}/tests/certs/openldap.crt":"/certs/openldap.crt" -v "${{ github.workspace }}/tests/certs/openldap.key":"/certs/openldap.key" -v "${{ github.workspace }}/tests/certs/CA.crt":"/certs/CA.crt" ghcr.io/joomla-projects/mirror-bitnami-openldap:latest
197- - uses : actions/cache/restore@v5
207+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
198208 with :
199209 path : libraries/vendor
200210 key : ${{ runner.os }}-composer-${{ hashFiles('composer.lock') }}
201- - uses : actions/cache/restore@v4
211+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
202212 with :
203213 path : plugins/system/webauthn/fido.jwt
204214 key : ${{ runner.os }}-webauthn-${{ hashFiles('composer.lock') }}
@@ -246,19 +256,19 @@ jobs:
246256 matrix :
247257 php_version : ['8.3', '8.4', '8.5']
248258 steps :
249- - uses : actions/checkout@v6
250- - uses : actions/cache/restore@v5
259+ - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
260+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
251261 id : cache-php-windows
252262 with :
253263 path : libraries/vendor
254264 key : ${{ runner.os }}-composer-${{ hashFiles('composer.lock') }}
255- - uses : actions/cache/restore@v4
265+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
256266 id : cache-webauthn-windows
257267 with :
258268 path : plugins/system/webauthn/fido.jwt
259269 key : ${{ runner.os }}-webauthn-${{ hashFiles('composer.lock') }}
260270 - name : Setup PHP
261- uses : shivammathur/setup-php@v2
271+ uses : shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # v2
262272 with :
263273 php-version : ${{ matrix.php_version }}
264274 extensions : openssl, mbstring, fileinfo, gd, gmp, pgsql, mysql, mysqli, curl, opcache, ldap
@@ -277,23 +287,23 @@ jobs:
277287 matrix :
278288 php_version : ['8.3', '8.4', '8.5']
279289 steps :
280- - uses : actions/checkout@v6
281- - uses : actions/cache/restore@v5
290+ - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
291+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
282292 with :
283293 path : libraries/vendor
284294 key : ${{ runner.os }}-composer-${{ hashFiles('composer.lock') }}
285- - uses : actions/cache/restore@v4
295+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
286296 with :
287297 path : plugins/system/webauthn/fido.jwt
288298 key : ${{ runner.os }}-webauthn-${{ hashFiles('composer.lock') }}
289- - uses : shogo82148/actions-setup-mysql@v1
299+ - uses : shogo82148/actions-setup-mysql@9c42ca180d5f1dd4dceb54c23c5eda0384f4d265 # v1.50.0
290300 with :
291301 mysql-version : " mariadb-10.4"
292302 root-password : " joomla_ut"
293303 user : " joomla_ut"
294304 password : " joomla_ut"
295305 - name : Setup PHP
296- uses : shivammathur/setup-php@v2
306+ uses : shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # v2
297307 with :
298308 php-version : ${{ matrix.php_version }}
299309 extensions : openssl, mbstring, fileinfo, gd, gmp, pgsql, mysql, mysqli, curl, opcache, ldap
@@ -316,8 +326,8 @@ jobs:
316326 env :
317327 CYPRESS_VERIFY_TIMEOUT : 100000
318328 steps :
319- - uses : actions/checkout@v6
320- - uses : actions/cache/restore@v5
329+ - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
330+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
321331 with :
322332 path : |
323333 node_modules
@@ -327,7 +337,7 @@ jobs:
327337 installation/template/js
328338 installation/template/scss
329339 key : ${{ runner.os }}-node-${{ hashFiles('package-lock.json', 'build/build.mjs', 'build/build-modules-js/**', 'media_source/**') }}
330- - uses : actions/cache@v5
340+ - uses : actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
331341 id : cache-cypress
332342 with :
333343 path : |
@@ -382,16 +392,16 @@ jobs:
382392 env :
383393 JOOMLA_INSTALLATION_DISABLE_LOCALHOST_CHECK : 1
384394 steps :
385- - uses : actions/checkout@v6
386- - uses : actions/cache/restore@v5
395+ - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
396+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
387397 with :
388398 path : libraries/vendor
389399 key : ${{ runner.os }}-composer-${{ hashFiles('composer.lock') }}
390- - uses : actions/cache/restore@v5
400+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
391401 with :
392402 path : plugins/system/webauthn/fido.jwt
393403 key : ${{ runner.os }}-webauthn-${{ hashFiles('composer.lock') }}
394- - uses : actions/cache/restore@v4
404+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
395405 with :
396406 path : |
397407 node_modules
@@ -401,7 +411,7 @@ jobs:
401411 installation/template/js
402412 installation/template/scss
403413 key : ${{ runner.os }}-node-${{ hashFiles('package-lock.json', 'build/build.mjs', 'build/build-modules-js/**', 'media_source/**') }}
404- - uses : actions/cache/restore@v5
414+ - uses : actions/cache/restore@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
405415 with :
406416 path : |
407417 /root/.cache/Cypress
@@ -410,7 +420,7 @@ jobs:
410420 - name : Run System tests
411421 run : bash tests/System/entrypoint.sh "$(pwd)" ${{ matrix.config.test_group }} ${{ matrix.config.db_engine }} ${{ matrix.config.db_host }} ${{ matrix.browser }}
412422 - name : Archive test results results
413- uses : actions/upload-artifact@v7
423+ uses : actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
414424 if : always()
415425 with :
416426 name : system-test-output
@@ -443,8 +453,8 @@ jobs:
443453 runs-on : ubuntu-latest
444454 steps :
445455 - name : Checkout Actions Repository
446- uses : actions/checkout@v6
456+ uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
447457 - name : Spell Check Repository
448- uses : crate-ci/typos@v1.34.0
458+ uses : crate-ci/typos@392b78fe18a52790c53f42456e46124f77346842 # v1.34.0
449459 with :
450460 config : .github/workflows/typos.toml
0 commit comments