Skip to content

Commit 52da5ea

Browse files
authored
Merge branch 'heroku:main' into master
2 parents 1518b31 + 16fa91f commit 52da5ea

259 files changed

Lines changed: 47687 additions & 10873 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/CODEOWNERS

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,16 @@
1+
# Default to requesting pull request reviews from the Heroku Languages team.
2+
#ECCN:Open Source
3+
#GUSINFO:Languages,Heroku Node.js Platform
14
* @heroku/languages
5+
6+
# However, request review from the language owner instead for files that are updated
7+
# by Dependabot or inventory/release automation, to reduce team review request noise.
8+
CHANGELOG.md @colincasey
9+
Gemfile.lock @colincasey
10+
inventory/ @colincasey
11+
npm-shrinkwrap.json @colincasey
12+
package.json @colincasey
13+
package-lock.json @colincasey
14+
pnpm-lock.yaml @colincasey
15+
yarn.lock @colincasey
16+
/.github/workflows/ @colincasey

.github/ISSUE_TEMPLATE/bug_report.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ Steps to reproduce the behavior:
2020
4. See error
2121

2222
**Versions (please complete the following information):**
23-
- Heroku Stack: [e.g. `heroku-20`]
23+
- Heroku Stack: [e.g. `heroku-22`]
2424
- Node Version: [e.g. `15.0.0`]
2525
- NPM or Yarn Version: [e.g. `Yarn 1.22.10`]
2626
- Buildpack Version: [e.g. `heroku/nodejs v175`] (We will try to do our best to support you, but please note that we can only provide support for the latest release of the buildpack.)

.github/dependabot.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,8 @@ updates:
2121
- "dependencies"
2222
- "github actions"
2323
- "skip changelog"
24+
groups:
25+
github-actions:
26+
update-types:
27+
- "minor"
28+
- "patch"

.github/workflows/check_changelog.yml

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

1010
jobs:
1111
check-changelog:
12-
runs-on: ubuntu-latest
12+
runs-on: ubuntu-24.04
1313
if: (!contains(github.event.pull_request.labels.*.name, 'skip changelog'))
1414
steps:
1515
- name: Checkout

.github/workflows/ci.yml

Lines changed: 24 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,13 @@ permissions:
1111
jobs:
1212

1313
unit-test:
14-
runs-on: ubuntu-22.04
14+
runs-on: ubuntu-24.04
1515
container:
1616
image: heroku/heroku:${{ matrix.stack_number }}-build
17+
options: --user root
1718
strategy:
1819
matrix:
19-
stack_number: ["20", "22"]
20+
stack_number: ["22", "24"]
2021
env:
2122
STACK: heroku-${{ matrix.stack_number }}
2223
steps:
@@ -26,12 +27,13 @@ jobs:
2627
run: test/unit
2728

2829
functional-test:
29-
runs-on: ubuntu-22.04
30+
runs-on: ubuntu-24.04
3031
container:
3132
image: heroku/heroku:${{ matrix.stack_number }}-build
33+
options: --user root
3234
strategy:
3335
matrix:
34-
stack_number: ["20", "22"]
36+
stack_number: ["22", "24"]
3537
env:
3638
STACK: heroku-${{ matrix.stack_number }}
3739
steps:
@@ -41,7 +43,7 @@ jobs:
4143
run: test/run
4244

4345
hatchet-test:
44-
runs-on: ubuntu-22.04
46+
runs-on: ubuntu-24.04
4547
env:
4648
HEROKU_API_KEY: ${{ secrets.HEROKU_API_KEY }}
4749
HEROKU_API_USER: ${{ secrets.HEROKU_API_USER }}
@@ -52,7 +54,23 @@ jobs:
5254
- name: Install Ruby and gems
5355
uses: ruby/setup-ruby@v1
5456
with:
55-
ruby-version: '2.7'
57+
ruby-version: 3.1
5658
bundler-cache: true
5759
- name: Run hatchet tests
5860
run: make hatchet
61+
62+
metrics-test:
63+
strategy:
64+
fail-fast: false
65+
matrix:
66+
# check the minimum node version supported by the metrics script and the latest node version
67+
# (assumes the versions between have backwards-compatible APIs)
68+
version: [14.10.0, latest]
69+
name: Test Metrics (${{ matrix.version }})
70+
runs-on: ubuntu-24.04
71+
steps:
72+
- uses: actions/checkout@v4
73+
- uses: actions/setup-node@v4
74+
with:
75+
node-version: ${{ matrix.version }}
76+
- run: npx mocha@10.x metrics/test/metrics.spec.cjs

.github/workflows/hatchet_app_cleaner.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Hatchet app cleaner
1+
name: Hatchet App Cleaner
22

33
on:
44
schedule:
@@ -12,7 +12,7 @@ permissions:
1212

1313
jobs:
1414
hatchet-app-cleaner:
15-
runs-on: ubuntu-latest
15+
runs-on: ubuntu-24.04
1616
env:
1717
HEROKU_API_KEY: ${{ secrets.HEROKU_API_KEY }}
1818
HEROKU_API_USER: ${{ secrets.HEROKU_API_USER }}
@@ -24,7 +24,7 @@ jobs:
2424
uses: ruby/setup-ruby@v1
2525
with:
2626
bundler-cache: true
27-
ruby-version: "2.7"
27+
ruby-version: 3.1
2828
- name: Run Hatchet destroy
2929
# Only apps older than 10 minutes are destroyed, to ensure that any
3030
# in progress CI runs are not interrupted.

.github/workflows/inventory.yml

Lines changed: 15 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -7,95 +7,41 @@ on:
77
jobs:
88
update-nodejs-inventory:
99
name: Update Node.js Engine Inventory
10-
runs-on: pub-hk-ubuntu-22.04-small
10+
runs-on: pub-hk-ubuntu-24.04-ip
1111
steps:
1212
- name: Checkout Repo
1313
uses: actions/checkout@v4
14-
- name: Install Rust Toolchain
15-
uses: actions-rs/toolchain@v1
16-
with:
17-
toolchain: stable
14+
- name: Update Rust toolchain
15+
run: rustup update
1816
- name: Install Rust Inventory Binaries
19-
run: cargo install heroku-nodejs-utils --bin diff_versions --bin generate_inventory --git https://github.com/heroku/buildpacks-nodejs
20-
- id: set-diff-msg
21-
name: Set Diff Message
17+
run: cargo install heroku-nodejs-utils --bin update_node_inventory --git https://github.com/heroku/buildpacks-nodejs
18+
- name: Rebuild Inventory
19+
id: rebuild-inventory
2220
run: |
2321
delimiter="$(openssl rand -hex 8)"
2422
{
2523
echo "msg<<${delimiter}"
26-
diff_versions node inventory/node.toml
24+
update_node_inventory ./inventory/node.toml ./CHANGELOG.md --platform linux-x64 --format classic
2725
echo "${delimiter}"
2826
} >> $GITHUB_OUTPUT
29-
- name: Rebuild Inventory
30-
run: "generate_inventory node > inventory/node.toml"
31-
- name: Update Changelog
32-
run: echo "${{ steps.set-diff-msg.outputs.msg }}" | xargs -r -I '{}' perl -i -p -e 's/## main\s+/## main\n\n{}/' CHANGELOG.md
33-
- uses: heroku/use-app-token-action@main
27+
- uses: actions/create-github-app-token@v2
3428
id: generate-token
3529
with:
36-
app_id: ${{ vars.LINGUIST_GH_APP_ID }}
37-
private_key: ${{ secrets.LINGUIST_GH_PRIVATE_KEY }}
30+
app-id: ${{ vars.LINGUIST_GH_APP_ID }}
31+
private-key: ${{ secrets.LINGUIST_GH_PRIVATE_KEY }}
3832
- name: Create Pull Request
3933
id: pr
40-
uses: peter-evans/create-pull-request@v5.0.2
34+
uses: peter-evans/create-pull-request@271a8d0340265f705b14b6d32b9829c1cb33d45e # v7.0.8
4135
with:
42-
token: ${{ steps.generate-token.outputs.app_token }}
36+
token: ${{ steps.generate-token.outputs.token }}
4337
title: "Update Node.js Engine Inventory"
44-
commit-message: "Update Inventory for heroku/nodejs engine\n\n${{ steps.set-diff-msg.outputs.msg }}"
38+
commit-message: "Update Inventory for heroku/nodejs-engine\n\n${{ steps.rebuild-inventory.outputs.msg }}"
4539
branch: update-nodejs-inventory
46-
body: "Automated pull-request to update heroku/nodejs engine inventory:\n\n${{ steps.set-diff-msg.outputs.msg }}"
47-
committer: ${{ vars.LINGUIST_GH_APP_USERNAME }} <${{ vars.LINGUIST_GH_APP_EMAIL }}>
48-
author: ${{ vars.LINGUIST_GH_APP_USERNAME }} <${{ vars.LINGUIST_GH_APP_EMAIL }}>
49-
- name: Configure PR
50-
if: steps.pr.outputs.pull-request-operation == 'created'
51-
run: gh pr merge --squash --auto "${{ steps.pr.outputs.pull-request-number }}"
52-
env:
53-
GH_TOKEN: ${{ steps.generate-token.outputs.app_token }}
54-
55-
update-yarn-inventory:
56-
name: Update Node.js Yarn Inventory
57-
runs-on: pub-hk-ubuntu-22.04-small
58-
steps:
59-
- name: Checkout Repo
60-
uses: actions/checkout@v4
61-
- id: install-rust-toolchain
62-
name: Install Rust Toolchain
63-
uses: actions-rs/toolchain@v1
64-
with:
65-
toolchain: stable
66-
- name: Install Rust Inventory Binaries
67-
run: cargo install heroku-nodejs-utils --bin diff_versions --bin generate_inventory --git https://github.com/heroku/buildpacks-nodejs
68-
- id: set-diff-msg
69-
name: Set Diff Message
70-
run: |
71-
delimiter="$(openssl rand -hex 8)"
72-
{
73-
echo "msg<<${delimiter}"
74-
diff_versions yarn inventory/yarn.toml
75-
echo "${delimiter}"
76-
} >> $GITHUB_OUTPUT
77-
- name: Rebuild Inventory
78-
run: "generate_inventory yarn > inventory/yarn.toml"
79-
- name: Update Changelog
80-
run: echo "${{ steps.set-diff-msg.outputs.msg }}" | xargs -r -I '{}' perl -i -p -e 's/## main\s+/## main\n\n{}/' CHANGELOG.md
81-
- uses: heroku/use-app-token-action@main
82-
id: generate-token
83-
with:
84-
app_id: ${{ vars.LINGUIST_GH_APP_ID }}
85-
private_key: ${{ secrets.LINGUIST_GH_PRIVATE_KEY }}
86-
- name: Create Pull Request
87-
id: pr
88-
uses: peter-evans/create-pull-request@v5.0.2
89-
with:
90-
token: ${{ steps.generate-token.outputs.app_token }}
91-
title: "Update Node.js Yarn Inventory"
92-
commit-message: "Update Inventory for heroku/nodejs yarn\n\n${{ steps.set-diff-msg.outputs.msg }}"
93-
branch: update-yarn-inventory
94-
body: "Automated pull-request to update heroku/nodejs yarn inventory:\n\n${{ steps.set-diff-msg.outputs.msg }}"
40+
body: "Automated pull-request to update heroku/nodejs-engine inventory:\n\n${{ steps.rebuild-inventory.outputs.msg }}"
9541
committer: ${{ vars.LINGUIST_GH_APP_USERNAME }} <${{ vars.LINGUIST_GH_APP_EMAIL }}>
9642
author: ${{ vars.LINGUIST_GH_APP_USERNAME }} <${{ vars.LINGUIST_GH_APP_EMAIL }}>
9743
- name: Configure PR
9844
if: steps.pr.outputs.pull-request-operation == 'created'
9945
run: gh pr merge --squash --auto "${{ steps.pr.outputs.pull-request-number }}"
10046
env:
101-
GH_TOKEN: ${{ steps.generate-token.outputs.app_token }}
47+
GH_TOKEN: ${{ steps.generate-token.outputs.token }}
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
name: Prepare Release
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
prepare-release:
8+
uses: heroku/languages-github-actions/.github/workflows/_classic-buildpack-prepare-release.yml@latest
9+
secrets: inherit

0 commit comments

Comments
 (0)