mirror of
https://github.com/public-transport/db-vendo-client.git
synced 2025-11-02 09:06:32 +02:00
chore: CI: publish to npm using OIDC tokens
see also https://docs.npmjs.com/trusted-publishers
This commit is contained in:
parent
c2216120c9
commit
5ef2eca999
1 changed files with 7 additions and 2 deletions
9
.github/workflows/build.yml
vendored
9
.github/workflows/build.yml
vendored
|
|
@ -10,6 +10,9 @@ env:
|
|||
REGISTRY: ghcr.io
|
||||
IMAGE_NAME: ${{ github.repository }}
|
||||
|
||||
permissions:
|
||||
id-token: write # for OIDC-based publishing to npm
|
||||
|
||||
jobs:
|
||||
build-and-push-docker:
|
||||
runs-on: ubuntu-latest
|
||||
|
|
@ -53,7 +56,9 @@ jobs:
|
|||
with:
|
||||
node-version: '20.x'
|
||||
registry-url: 'https://registry.npmjs.org'
|
||||
# for OIDC-based publishing to npm
|
||||
- name: setup npm v11
|
||||
run: npm install -g npm@11
|
||||
|
||||
- run: npm ci
|
||||
- run: npm publish --provenance --access public
|
||||
env:
|
||||
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
||||
Loading…
Add table
Reference in a new issue