From 0aedad51927718726b33c1debb7af3e05e835032 Mon Sep 17 00:00:00 2001 From: Traines Date: Tue, 17 Dec 2024 16:04:41 +0000 Subject: [PATCH] build workflow --- .github/workflows/build.yml | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 .github/workflows/build.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 00000000..c92f0312 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,35 @@ +name: Build NPM Package & Docker + +on: + push: + branches: [ "main" ] + +jobs: + test: + name: test + uses: './.github/workflows/test.yml' + + build-docker: + needs: [test] + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Build the Docker image + run: docker build . --file Dockerfile --tag db-vendo-client:6 + + build-pkg: + needs: [test] + runs-on: ubuntu-latest + permissions: + contents: read + packages: write + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: '20.x' + registry-url: 'https://npm.pkg.github.com' + - run: npm ci + - run: npm publish + env: + NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file