Skip to content

Commit 97c2d37

Browse files
ci(actions): Update workflow templates from organization template repository
Signed-off-by: GitHub <[email protected]>
1 parent 9648a6e commit 97c2d37

16 files changed

Lines changed: 124 additions & 192 deletions

.github/actions-lock.txt

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# SPDX-FileCopyrightText: 2025 Nextcloud GmbH and Nextcloud contributors
2+
# SPDX-License-Identifier: MIT
3+
25fc4c7e69e778e20bdc9eb0cc96367e block-merge-freeze.yml
4+
389be040fb297cf15b006d2f8094a6d0 documentation.yml
5+
2a205b6cc57c26c31a18a7f41190f3e2 lint-eslint.yml
6+
870b483dbcbca59479211270d61546dd lint-php-cs.yml
7+
ee2b04d185b82fe7dd6fe6d83c6c7b45 lint-php.yml
8+
50216efd4562e58dd14aa181e1bb5df0 lint-typescript.yml
9+
03759c9dc0fa748cb927b9f9cadf2925 node.yml
10+
07e60b2f304c749ee563f1256caf2793 phpunit-mysql.yml
11+
b98798d397dd45f12c777038d230509e phpunit-oci.yml
12+
4bf29a4d193f83443d16d368c60a7870 phpunit-pgsql.yml
13+
21244b02c3f1ad7d78951ba1b876638f phpunit-sqlite.yml
14+
3c4a096b3b7dbaef0f8e5190ffe13518 pr-feedback.yml
15+
20b5d0d45766e3793f19c9c0c8d05140 psalm.yml
16+
3975dc58817119d596a8f6ed190352ce reuse.yml
17+
a3440826636c0fd7c2d20b1de50363da update-nextcloud-ocp-approve-merge.yml
18+
39db87018db395caf41007931817cdbd update-nextcloud-ocp.yml

.github/workflows/block-merge-freeze.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929

3030
steps:
3131
- name: Register server reference to fallback to master branch
32-
uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd # v8.0.0
32+
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
3333
with:
3434
github-token: ${{secrets.GITHUB_TOKEN}}
3535
script: |

.github/workflows/documentation.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,12 @@ jobs:
2525
- name: Check actor permission level
2626
# Only allow admin to deploy on release
2727
if: github.event.release
28-
uses: skjnldsv/check-actor-permission@69e92a3c4711150929bca9fcf34448c5bf5526e7 # v2
28+
uses: skjnldsv/check-actor-permission@69e92a3c4711150929bca9fcf34448c5bf5526e7 # v3.0
2929
with:
3030
require: admin
3131

3232
- name: Checkout
33-
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
33+
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
3434
with:
3535
persist-credentials: false
3636

@@ -42,9 +42,10 @@ jobs:
4242
fallbackNpm: '^11.3'
4343

4444
- name: Set up node ${{ steps.versions.outputs.nodeVersion }}
45-
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6.0.0
45+
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
4646
with:
4747
node-version: ${{ steps.versions.outputs.nodeVersion }}
48+
package-manager-cache: false
4849

4950
- name: Set up npm ${{ steps.versions.outputs.npmVersion }}
5051
run: npm i -g 'npm@${{ steps.versions.outputs.npmVersion }}'
@@ -60,7 +61,7 @@ jobs:
6061
- name: Deploy
6162
# Only deploy on release
6263
if: github.event.release
63-
uses: peaceiris/actions-gh-pages@4f9cc6602d3f66b9c108549d475ec49e8ef4d45e # v4.0.0
64+
uses: peaceiris/actions-gh-pages@84c30a85c19949d7eee79c4ff27748b70285e453 # v4.1.0
6465
with:
6566
github_token: ${{ secrets.GITHUB_TOKEN }}
6667
publish_dir: ./dist/doc

.github/workflows/lint-eslint.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
src: ${{ steps.changes.outputs.src}}
2929

3030
steps:
31-
- uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2
31+
- uses: dorny/paths-filter@fbd0ab8f3e69293af611ebaee6363fc25e6d187d # v4.0.1
3232
id: changes
3333
continue-on-error: true
3434
with:
@@ -56,7 +56,7 @@ jobs:
5656

5757
steps:
5858
- name: Checkout
59-
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
59+
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
6060
with:
6161
persist-credentials: false
6262

@@ -68,7 +68,7 @@ jobs:
6868
fallbackNpm: '^11.3'
6969

7070
- name: Set up node ${{ steps.versions.outputs.nodeVersion }}
71-
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6.0.0
71+
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
7272
with:
7373
node-version: ${{ steps.versions.outputs.nodeVersion }}
7474

.github/workflows/lint-php-cs.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,16 +25,16 @@ jobs:
2525

2626
steps:
2727
- name: Checkout
28-
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
28+
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
2929
with:
3030
persist-credentials: false
3131

3232
- name: Get php version
3333
id: versions
34-
uses: icewind1991/nextcloud-version-matrix@58becf3b4bb6dc6cef677b15e2fd8e7d48c0908f # v1.3.1
34+
uses: icewind1991/nextcloud-version-matrix@8a7bac6300b2f0f3100088b297995a229558ddba # v1.3.2
3535

3636
- name: Set up php${{ steps.versions.outputs.php-min }}
37-
uses: shivammathur/setup-php@bf6b4fbd49ca58e4608c9c89fba0b8d90bd2a39f # v2.35.5
37+
uses: shivammathur/setup-php@f3e473d116dcccaddc5834248c87452386958240 # 2.37.2
3838
with:
3939
php-version: ${{ steps.versions.outputs.php-min }}
4040
extensions: bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, sqlite, pdo_sqlite

.github/workflows/lint-php.yml

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -21,34 +21,35 @@ jobs:
2121
matrix:
2222
runs-on: ubuntu-latest-low
2323
outputs:
24-
php-versions: ${{ steps.versions.outputs.php-versions }}
24+
php-min: ${{ steps.versions.outputs.php-min }}
25+
php-max: ${{ steps.versions.outputs.php-max }}
2526
steps:
2627
- name: Checkout app
27-
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
28+
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
2829
with:
2930
persist-credentials: false
3031

3132
- name: Get version matrix
3233
id: versions
33-
uses: icewind1991/nextcloud-version-matrix@58becf3b4bb6dc6cef677b15e2fd8e7d48c0908f # v1.0.0
34+
uses: icewind1991/nextcloud-version-matrix@8a7bac6300b2f0f3100088b297995a229558ddba # v1.3.2
3435

3536
php-lint:
36-
runs-on: ubuntu-latest
37+
runs-on: ubuntu-latest-low
3738
needs: matrix
3839
strategy:
3940
matrix:
40-
php-versions: ${{fromJson(needs.matrix.outputs.php-versions)}}
41+
php-versions: ['${{ needs.matrix.outputs.php-min }}', '${{ needs.matrix.outputs.php-max }}']
4142

4243
name: php-lint
4344

4445
steps:
4546
- name: Checkout
46-
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
47+
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
4748
with:
4849
persist-credentials: false
4950

5051
- name: Set up php ${{ matrix.php-versions }}
51-
uses: shivammathur/setup-php@bf6b4fbd49ca58e4608c9c89fba0b8d90bd2a39f # v2.35.5
52+
uses: shivammathur/setup-php@f3e473d116dcccaddc5834248c87452386958240 # 2.37.2
5253
with:
5354
php-version: ${{ matrix.php-versions }}
5455
extensions: bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, sqlite, pdo_sqlite

.github/workflows/lint-typescript.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ jobs:
3434
src: ${{ steps.changes.outputs.src}}
3535

3636
steps:
37-
- uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2
37+
- uses: dorny/paths-filter@fbd0ab8f3e69293af611ebaee6363fc25e6d187d # v4.0.1
3838
id: changes
3939
continue-on-error: true
4040
with:
@@ -55,7 +55,7 @@ jobs:
5555

5656
steps:
5757
- name: Checkout
58-
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
58+
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
5959
with:
6060
persist-credentials: false
6161

@@ -67,7 +67,7 @@ jobs:
6767
fallbackNpm: '^11.3'
6868

6969
- name: Set up node ${{ steps.versions.outputs.nodeVersion }}
70-
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6.0.0
70+
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
7171
with:
7272
node-version: ${{ steps.versions.outputs.nodeVersion }}
7373

.github/workflows/node.yml

Lines changed: 6 additions & 87 deletions
Original file line numberDiff line numberDiff line change
@@ -6,108 +6,27 @@
66
# SPDX-FileCopyrightText: 2021-2024 Nextcloud GmbH and Nextcloud contributors
77
# SPDX-License-Identifier: MIT
88

9-
name: Node
9+
# TODO: Remove this after a grace period of 6 months to give everyone the chance to switch to the new workflow name
10+
# TODO: To be removed end of 2026.
11+
name: No-op please switch to npm-build.yml
1012

1113
on: pull_request
1214

1315
permissions:
14-
contents: read
16+
contents: none
1517

1618
concurrency:
1719
group: node-${{ github.head_ref || github.run_id }}
1820
cancel-in-progress: true
1921

2022
jobs:
21-
changes:
22-
runs-on: ubuntu-latest-low
23-
permissions:
24-
contents: read
25-
pull-requests: read
26-
27-
outputs:
28-
src: ${{ steps.changes.outputs.src}}
29-
30-
steps:
31-
- uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2
32-
id: changes
33-
continue-on-error: true
34-
with:
35-
filters: |
36-
src:
37-
- '.github/workflows/**'
38-
- 'src/**'
39-
- 'appinfo/info.xml'
40-
- 'package.json'
41-
- 'package-lock.json'
42-
- 'tsconfig.json'
43-
- '**.js'
44-
- '**.ts'
45-
- '**.vue'
46-
47-
build:
48-
runs-on: ubuntu-latest
49-
50-
needs: changes
51-
if: needs.changes.outputs.src != 'false'
52-
53-
name: NPM build
54-
steps:
55-
- name: Checkout
56-
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
57-
with:
58-
persist-credentials: false
59-
60-
- name: Read package.json node and npm engines version
61-
uses: skjnldsv/read-package-engines-version-actions@06d6baf7d8f41934ab630e97d9e6c0bc9c9ac5e4 # v3
62-
id: versions
63-
with:
64-
fallbackNode: '^24'
65-
fallbackNpm: '^11.3'
66-
67-
- name: Set up node ${{ steps.versions.outputs.nodeVersion }}
68-
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6.0.0
69-
with:
70-
node-version: ${{ steps.versions.outputs.nodeVersion }}
71-
72-
- name: Set up npm ${{ steps.versions.outputs.npmVersion }}
73-
run: npm i -g 'npm@${{ steps.versions.outputs.npmVersion }}'
74-
75-
- name: Validate package-lock.json # See https://github.com/npm/cli/issues/4460
76-
run: |
77-
78-
npm-package-lock-add-resolved
79-
git --no-pager diff --exit-code
80-
81-
- name: Install dependencies & build
82-
env:
83-
CYPRESS_INSTALL_BINARY: 0
84-
PUPPETEER_SKIP_DOWNLOAD: true
85-
run: |
86-
npm ci
87-
npm run build --if-present
88-
89-
- name: Check build changes
90-
run: |
91-
bash -c "[[ ! \"`git status --porcelain `\" ]] || (echo 'Please recompile and commit the assets, see the section \"Show changes on failure\" for details' && exit 1)"
92-
93-
- name: Show changes on failure
94-
if: failure()
95-
run: |
96-
git status
97-
git --no-pager diff
98-
exit 1 # make it red to grab attention
99-
10023
summary:
101-
permissions:
102-
contents: none
10324
runs-on: ubuntu-latest-low
104-
needs: [changes, build]
105-
10625
if: always()
10726

10827
# This is the summary, we just avoid to rename it so that branch protection rules still match
10928
name: node
11029

11130
steps:
112-
- name: Summary status
113-
run: if ${{ needs.changes.outputs.src != 'false' && needs.build.result != 'success' }}; then exit 1; fi
31+
- name: No-op please switch to npm-build.yml
32+
run: echo "The workflow has been renamed, please switch to npm-build.yml from organization templates"; exit 1;

.github/workflows/phpunit-mysql.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,13 @@ jobs:
2424
matrix: ${{ steps.versions.outputs.sparse-matrix }}
2525
steps:
2626
- name: Checkout app
27-
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
27+
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
2828
with:
2929
persist-credentials: false
3030

3131
- name: Get version matrix
3232
id: versions
33-
uses: icewind1991/nextcloud-version-matrix@58becf3b4bb6dc6cef677b15e2fd8e7d48c0908f # v1.3.1
33+
uses: icewind1991/nextcloud-version-matrix@8a7bac6300b2f0f3100088b297995a229558ddba # v1.3.2
3434
with:
3535
matrix: '{"mysql-versions": ["8.4"]}'
3636

@@ -44,7 +44,7 @@ jobs:
4444
src: ${{ steps.changes.outputs.src}}
4545

4646
steps:
47-
- uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2
47+
- uses: dorny/paths-filter@fbd0ab8f3e69293af611ebaee6363fc25e6d187d # v4.0.1
4848
id: changes
4949
continue-on-error: true
5050
with:
@@ -89,21 +89,21 @@ jobs:
8989
echo "APP_NAME=${GITHUB_REPOSITORY##*/}" >> $GITHUB_ENV
9090
9191
- name: Checkout server
92-
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
92+
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
9393
with:
9494
persist-credentials: false
9595
submodules: true
9696
repository: nextcloud/server
9797
ref: ${{ matrix.server-versions }}
9898

9999
- name: Checkout app
100-
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
100+
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
101101
with:
102102
persist-credentials: false
103103
path: apps/${{ env.APP_NAME }}
104104

105105
- name: Set up php ${{ matrix.php-versions }}
106-
uses: shivammathur/setup-php@bf6b4fbd49ca58e4608c9c89fba0b8d90bd2a39f # v2.35.5
106+
uses: shivammathur/setup-php@f3e473d116dcccaddc5834248c87452386958240 # 2.37.2
107107
with:
108108
php-version: ${{ matrix.php-versions }}
109109
# https://docs.nextcloud.com/server/stable/admin_manual/installation/source_installation.html#prerequisites-for-manual-installation
@@ -122,7 +122,7 @@ jobs:
122122
123123
- name: Check composer file existence
124124
id: check_composer
125-
uses: andstor/file-existence-action@076e0072799f4942c8bc574a82233e1e4d13e9d6 # v3.0.0
125+
uses: andstor/file-existence-action@558493d6c74bf472d87c84eab196434afc2fa029 # v3.1.0
126126
with:
127127
files: apps/${{ env.APP_NAME }}/composer.json
128128

0 commit comments

Comments
 (0)