Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,39 +1,51 @@
name: Node.js CI

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
branches: [main]
workflow_dispatch:

permissions:
contents: read

concurrency:
group: nodejs-ci-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
build:
strategy:
fail-fast: false
matrix:
node-version: [20.x, 22.x, 24.x]
node-version: [22.x, 24.x, 26.x]
os: [ubuntu-latest, windows-latest]
runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v6
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v6
with:
node-version: ${{ matrix.node-version }}

- run: npm ci
- run: npm run build --if-present
- run: npm test

- name: Coveralls Parallel
uses: coverallsapp/github-action@master
uses: coverallsapp/github-action@v2
with:
github-token: ${{ secrets.github_token }}
github-token: ${{ secrets.GITHUB_TOKEN }}
flag-name: run-${{ matrix.node-version }}
parallel: true

finish:
name: Node.js CI
needs: build
runs-on: ubuntu-latest
steps:
- name: Coveralls Finished
uses: coverallsapp/github-action@master
uses: coverallsapp/github-action@v2
with:
github-token: ${{ secrets.github_token }}
parallel-finished: true
github-token: ${{ secrets.GITHUB_TOKEN }}
parallel-finished: true
36 changes: 28 additions & 8 deletions .github/workflows/release-please.yaml
Original file line number Diff line number Diff line change
@@ -1,29 +1,49 @@
name: release-please
on:
push:
branches:
- main
name: release-please

permissions:
contents: write
issues: write
pull-requests: write
id-token: write

jobs:
release-please:
runs-on: ubuntu-latest
outputs:
release_created: ${{ steps.release.outputs.release_created }}
steps:
- uses: GoogleCloudPlatform/release-please-action@v5
- uses: googleapis/release-please-action@v4
id: release
with:
token: ${{ secrets.NODESHIFT_RELEASES_TOKEN }}
release-type: node
bump-minor-pre-major: "true"
package-name: faas-js-runtime
changelog-types: '[{"type":"enhancement","section":"Features","hidden":false},{"type":"fix","section":"Bug Fixes","hidden":false},{"type":"chore","section":"Miscellaneous","hidden":false},{"type":"cleanup","section":"Miscellaneous","hidden":false},{"type":"api-change","section":"API Changes","hidden":false},{"type":"documentation","section":"Documentation","hidden":false},{"type":"techdebt","section":"Miscellaneous","hidden":false},{"type":"proposal","section":"Miscellaneous","hidden":false},{"type":"feat","section":"Features","hidden":false}]'

publish:
runs-on: ubuntu-latest
needs: release-please
if: needs.release-please.outputs.release_created == 'true'

steps:
- uses: actions/checkout@v6
with:
ref: release-please--branches--main--components--faas-js-runtime
- name: Update package SBOM
if: ${{steps.release.outputs.release-created}} == 'false'
run: |
git config --global user.name "NodeShift Bot (As Luke Holmquist)"
git config --global user.email "lholmqui@redhat.com"
npm run sbom
git add .
git commit --signoff -m "chore: update SBOM"
git push origin release-please--branches--main--components--faas-js-runtime
git push origin release-please--branches--main--components--faas-js-runtime

- uses: actions/setup-node@v6
with:
node-version: 24
registry-url: "https://registry.npmjs.org"
package-manager-cache: false
- run: npm ci
- run: npm test
- run: npm publish
21 changes: 0 additions & 21 deletions .github/workflows/release.yaml

This file was deleted.

3 changes: 3 additions & 0 deletions .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
".": "3.0.2"
}
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ path, allowing you to execute a single file as a function.
| --------------- | ------------- |
| License: | Apache-2.0 |
| Issue tracker: | https://github.com/nodeshift/faas-js-runtime/issues |
| Engines: | Node.js >= 20 |
| Engines: | Node.js >= 22 |

The function is loaded and then invoked for incoming HTTP requests
at `localhost:8080`. The incoming request may be a
Expand Down
40 changes: 30 additions & 10 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"author": "Red Hat, Inc.",
"license": "Apache-2.0",
"engines": {
"node": "^24 || ^22 || ^20"
"node": "^24 || ^22"
},
"type": "commonjs",
"scripts": {
Expand Down Expand Up @@ -47,7 +47,7 @@
},
"devDependencies": {
"@cyclonedx/cyclonedx-npm": "^3.0.0",
"@types/node": "^20.4.7",
"@types/node": "^24.0.0",
"@typescript-eslint/eslint-plugin": "^6.4.0",
"@typescript-eslint/parser": "^6.4.1",
"colortape": "^0.1.2",
Expand Down
57 changes: 57 additions & 0 deletions release-please-config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
{
"$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json",
"bump-minor-pre-major": true,
"packages": {
".": {
"release-type": "node",
"include-component-in-tag": false,
"changelog-sections": [
{
"type": "enhancement",
"section": "Features",
"hidden": false
},
{
"type": "fix",
"section": "Bug Fixes",
"hidden": false
},
{
"type": "chore",
"section": "Miscellaneous",
"hidden": false
},
{
"type": "cleanup",
"section": "Miscellaneous",
"hidden": false
},
{
"type": "api-change",
"section": "API Changes",
"hidden": false
},
{
"type": "documentation",
"section": "Documentation",
"hidden": false
},
{
"type": "techdebt",
"section": "Miscellaneous",
"hidden": false
},
{
"type": "proposal",
"section": "Miscellaneous",
"hidden": false
},
{
"type": "feat",
"section": "Features",
"hidden": false
}
]
}
}
}