Skip to content

Merge pull request #9 from insight-platform/github-actions #15

Merge pull request #9 from insight-platform/github-actions

Merge pull request #9 from insight-platform/github-actions #15

Workflow file for this run

name: Publish lib
on: [push]
jobs:
build:
runs-on: ubuntu-latest
if: "startsWith(github.ref, 'refs/tags/')"
permissions:
packages: write
contents: read
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: '16'
registry-url: 'https://npm.pkg.github.com'
scope: '@insight-platform'
- name: Build the Docker image
run: docker build . --file projects/savant-lib/Dockerfile --tag savant-image
- name: Publish from image
run: docker run savant-image bash -c "npm config set @insight-platform:registry=https://npm.pkg.github.com; npm config set -- '//npm.pkg.github.com/:_authToken' '${{ secrets.GITHUB_TOKEN }}'; npm version patch; npm publish"