From 155d85acd0a5066eb6313c73e5a51d64b805d1db Mon Sep 17 00:00:00 2001 From: mootz12 Date: Thu, 3 Oct 2024 09:14:32 -0400 Subject: [PATCH] ci: add npm build step before docker buildx --- .github/workflows/publish_docker.yml | 15 +++++++++++++++ .github/workflows/tests.yml | 28 ++++++++++++++-------------- 2 files changed, 29 insertions(+), 14 deletions(-) diff --git a/.github/workflows/publish_docker.yml b/.github/workflows/publish_docker.yml index 53f1304..eaee55d 100644 --- a/.github/workflows/publish_docker.yml +++ b/.github/workflows/publish_docker.yml @@ -9,6 +9,21 @@ jobs: docker: runs-on: ubuntu-latest steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Use Node.js + uses: actions/setup-node@v4 + with: + node-version: '20' + cache: 'npm' + + - name: Install dependencies + run: npm ci + + - name: Build + run: npm run build + - name: Set up QEMU uses: docker/setup-qemu-action@v3 diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index fd41d9b..42269ae 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -8,21 +8,21 @@ on: jobs: test: runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 + - name: Checkout code + uses: actions/checkout@v4 - - name: Use Node.js - uses: actions/setup-node@v4 - with: - node-version: '20' - cache: 'npm' + - name: Use Node.js + uses: actions/setup-node@v4 + with: + node-version: '20' + cache: 'npm' - - name: Install dependencies - run: npm ci - - - name: Build - run: npm run build + - name: Install dependencies + run: npm ci + + - name: Build + run: npm run build - - name: Run tests - run: npm run test \ No newline at end of file + - name: Run tests + run: npm run test \ No newline at end of file