Skip to content

Commit 6bd7877

Browse files
committed
chore(ci): make cost-saving changes
1 parent ec16468 commit 6bd7877

17 files changed

+37
-25
lines changed

.github/workflows/build.yml

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,17 @@ jobs:
3737
strategy:
3838
fail-fast: false
3939
matrix:
40-
os: [ubuntu-latest, windows-latest]
41-
40+
os: [ubuntu-slim, windows-latest]
41+
event-name: ${{ github.event_name }}
42+
repo: ${{ github.repository }}
43+
exclude:
44+
- os: windows-latest
45+
# Skipping the Windows build on the merge queue to speed it up
46+
event-name: merge_group
47+
- os: windows-latest
48+
# Skipping the Windows build on the private repo to save on costs
49+
repo: nodejs-private/nodejs.org-private
50+
4251
steps:
4352
- uses: nodejs/web-team/actions/setup-environment@9f3c83af227d721768d9dbb63009a47ed4f4282f
4453
with:
@@ -68,10 +77,10 @@ jobs:
6877
# but in general this should never happen
6978
NODE_OPTIONS: '--max_old_space_size=4096'
7079
# See https://github.com/vercel/next.js/pull/81318
71-
TURBOPACK_STATS: ${{ matrix.os == 'ubuntu-latest' }}
80+
TURBOPACK_STATS: ${{ matrix.os == 'ubuntu-slim' }}
7281

7382
- uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
74-
if: matrix.os == 'ubuntu-latest'
83+
if: matrix.os == 'ubuntu-slim'
7584
with:
7685
name: webpack-stats
7786
path: apps/site/.next/server/webpack-stats.json

.github/workflows/bundle-compare.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ permissions:
1414
jobs:
1515
compare:
1616
name: Compare Bundle Stats
17-
runs-on: ubuntu-latest
17+
runs-on: ubuntu-slim
1818
if: github.event.workflow_run.event == 'pull_request'
1919

2020
steps:

.github/workflows/chromatic.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ jobs:
4646
)
4747
4848
name: Chromatic
49-
runs-on: ubuntu-latest
49+
runs-on: ubuntu-slim
5050

5151
environment:
5252
name: Storybook

.github/workflows/create-release-post.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ permissions:
2525

2626
jobs:
2727
create-post:
28-
runs-on: ubuntu-latest
28+
runs-on: ubuntu-slim
2929

3030
steps:
3131
- uses: nodejs/web-team/actions/setup-environment@9f3c83af227d721768d9dbb63009a47ed4f4282f

.github/workflows/lighthouse.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ jobs:
3333
startsWith(github.event.pull_request.head.ref, 'dependabot/') == false &&
3434
github.event.label.name == 'github_actions:pull-request'
3535
name: Get Vercel Preview
36-
runs-on: ubuntu-latest
36+
runs-on: ubuntu-slim
3737
outputs:
3838
deployment_found: ${{ steps.set_outputs.outputs.deployment_found }}
3939
url: ${{ steps.set_outputs.outputs.url }}
@@ -61,7 +61,7 @@ jobs:
6161
needs: get-vercel-preview
6262
if: needs.get-vercel-preview.outputs.deployment_found == 'true'
6363
name: Lighthouse Report
64-
runs-on: ubuntu-latest
64+
runs-on: ubuntu-slim
6565

6666
steps:
6767
- name: Harden Runner

.github/workflows/lint-and-tests.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ env:
4040
jobs:
4141
lint:
4242
name: Quality checks
43-
runs-on: ubuntu-latest
43+
runs-on: ubuntu-slim
4444

4545
steps:
4646
- uses: nodejs/web-team/actions/setup-environment@9f3c83af227d721768d9dbb63009a47ed4f4282f
@@ -97,7 +97,7 @@ jobs:
9797

9898
tests:
9999
name: Tests
100-
runs-on: ubuntu-latest
100+
runs-on: ubuntu-slim
101101

102102
steps:
103103
- uses: nodejs/web-team/actions/setup-environment@9f3c83af227d721768d9dbb63009a47ed4f4282f

.github/workflows/notify-on-push.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@ jobs:
1313
if: >
1414
github.repository == 'nodejs/nodejs.org' &&
1515
github.actor != 'github-merge-queue[bot]'
16-
runs-on: ubuntu-latest
16+
# cannot use ubuntu-slim here because rtCamp/action-slack-notify is dockerized
17+
runs-on: ubuntu-24.04-arm
1718
steps:
1819
- uses: nodejs/web-team/actions/notify-on-push@9f3c83af227d721768d9dbb63009a47ed4f4282f
1920
with:

.github/workflows/playwright-cloudflare-open-next.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ permissions:
2525
jobs:
2626
playwright:
2727
name: Playwright Tests
28-
runs-on: ubuntu-latest
28+
runs-on: ubuntu-slim
2929

3030
steps:
3131
- uses: nodejs/web-team/actions/setup-environment@9f3c83af227d721768d9dbb63009a47ed4f4282f

.github/workflows/playwright.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ permissions:
2323
jobs:
2424
get-vercel-preview:
2525
name: Get Vercel Preview
26-
runs-on: ubuntu-latest
26+
runs-on: ubuntu-slim
2727
outputs:
2828
deployment_found: ${{ steps.set_outputs.outputs.deployment_found }}
2929
url: ${{ steps.set_outputs.outputs.url }}
@@ -51,7 +51,7 @@ jobs:
5151
needs: get-vercel-preview
5252
if: needs.get-vercel-preview.outputs.deployment_found == 'true'
5353
name: Playwright Tests
54-
runs-on: ubuntu-latest
54+
runs-on: ubuntu-slim
5555

5656
steps:
5757
- uses: nodejs/web-team/actions/setup-environment@9f3c83af227d721768d9dbb63009a47ed4f4282f

.github/workflows/publish-packages.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ env:
2525

2626
jobs:
2727
prepare-packages:
28-
runs-on: ubuntu-latest
28+
runs-on: ubuntu-slim
2929
outputs:
3030
# Output the matrix of packages to publish for use in the publish job
3131
matrix: ${{ steps.generate-matrix.outputs.matrix }}
@@ -96,7 +96,8 @@ jobs:
9696
9797
publish:
9898
needs: prepare-packages
99-
runs-on: ubuntu-latest
99+
# cannot use ubuntu-slim here because rtCamp/action-slack-notify is dockerized
100+
runs-on: ubuntu-24.04-arm
100101
# Skip if no packages need to be published
101102
if: fromJson(needs.prepare-packages.outputs.matrix).package[0] != null
102103
# Use the dynamic matrix from prepare-packages job to create parallel jobs for each package

0 commit comments

Comments
 (0)