Skip to content

Commit b90a9b7

Browse files
feat: new release pipeline with trusted publishing (#1920)
* chore: fix release pipeline to support trusted publishing Signed-off-by: Shurtu-gal <ashishpadhy1729@gmail.com> * fix: resolve Next.js version mismatch for studio/preview * fix: remove unnecessary type assertions in Studio and Preview * chore: remove next.js package Signed-off-by: Shurtu-gal <ashishpadhy1729@gmail.com> * chore: remove @swc/core Signed-off-by: Shurtu-gal <ashishpadhy1729@gmail.com> * chore: reinstall packages Signed-off-by: Shurtu-gal <ashishpadhy1729@gmail.com> * chore: pin helpers to 0.2.0 version Signed-off-by: Shurtu-gal <ashishpadhy1729@gmail.com> * chore: fix tests Signed-off-by: Shurtu-gal <ashishpadhy1729@gmail.com> * chore: add repository URL Signed-off-by: Shurtu-gal <ashishpadhy1729@gmail.com> * chore: add changeset Signed-off-by: Shurtu-gal <ashishpadhy1729@gmail.com> --------- Signed-off-by: Shurtu-gal <ashishpadhy1729@gmail.com> Co-authored-by: kartikayy007 <kartikayy6969@gmail.com>
1 parent 495e8c5 commit b90a9b7

7 files changed

Lines changed: 8341 additions & 4766 deletions

File tree

.changeset/shaggy-masks-rescue.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
---
2+
'@asyncapi/cli': major
3+
---
4+
5+
## Major release with important security updates
6+
7+
- Keeping in mind the recent Shai-Hulud attack, we have adopted trusted publishing with NPM.
8+
- This requires us to use node >= 24 and npm >= 11
9+
- Next.js version is in sync with Studio, and is currently 14.2.35 deemed safe by CVE. [For more details](https://nextjs.org/blog/CVE-2025-66478)
10+
11+
### Breaking Changes
12+
- Node.js version 24 or higher is now required.
13+
- NPM version 11 or higher is now required.
14+
- Next.js version is now 14.2.35 or higher.
15+
16+
Please make sure to update your environment accordingly before upgrading to this version.

.github/workflows/release-with-changesets.yml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,7 @@ jobs:
3232
runs-on: ${{ matrix.os }}
3333
strategy:
3434
matrix:
35-
# Using macos-13 instead of latest (macos-14) due to an issue with Puppeteer and such runner.
36-
# See: https://github.com/puppeteer/puppeteer/issues/12327 and https://github.com/asyncapi/parser-js/issues/1001
37-
os: [ubuntu-latest, macos-13, windows-latest]
35+
os: [ubuntu-latest, macos-latest, windows-latest]
3836
steps:
3937
- name: Set git to use LF # To once and for all finish the never-ending fight between Unix and Windows
4038
run: |
@@ -82,6 +80,10 @@ jobs:
8280
needs: [test-nodejs]
8381
name: Publish to any of NPM, GitHub, or Docker Hub
8482
runs-on: ubuntu-latest
83+
permissions:
84+
contents: write
85+
id-token: write
86+
pull-requests: write
8587
steps:
8688
- name: Set git to use LF # To once and for all finish the never-ending fight between Unix and Windows
8789
run: |
@@ -97,10 +99,13 @@ jobs:
9799
name: Check package-lock version
98100
uses: asyncapi/.github/.github/actions/get-node-version-from-package-lock@master
99101
id: lockversion
102+
with:
103+
node-version: ${{ vars.NODE_VERSION }}
100104
- if: steps.packagejson.outputs.exists == 'true'
101105
name: Setup Node.js
102106
uses: actions/setup-node@v4
103107
with:
108+
registry-url: "https://registry.npmjs.org"
104109
node-version: "${{ steps.lockversion.outputs.version }}"
105110
- if: steps.packagejson.outputs.exists == 'true'
106111
name: Install dependencies
@@ -124,7 +129,6 @@ jobs:
124129
setupGitUser: false
125130
env:
126131
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
127-
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
128132
GIT_AUTHOR_NAME: asyncapi-bot
129133
GIT_AUTHOR_EMAIL: info@asyncapi.io
130134
GIT_COMMITTER_NAME: asyncapi-bot

0 commit comments

Comments
 (0)