diff --git a/.github/workflows/build-with-docker.yml b/.github/workflows/build-with-docker.yml new file mode 100644 index 00000000..e629c802 --- /dev/null +++ b/.github/workflows/build-with-docker.yml @@ -0,0 +1,43 @@ +name: Install, Lint, Test and Build + +on: [push, pull_request] + +jobs: + build: + runs-on: ubuntu-latest + container: + image: debian:latest + + strategy: + fail-fast: false + matrix: + node-version: [18.x, 20.x, 21.x] + os: [debian-latest] + + steps: + - uses: actions/checkout@v4 + + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - name: Install dependencies + run: npm install + + - name: Lint the project + run: npm run lint + + - name: Test the project + run: npm run test + + - name: Build the project + run: npm run build + + - name: List, audit, fix outdated dependencies and build again + run: | + npm list --outdated + npm audit || true # ignore failures + npm audit fix || true + npm list --outdated + npm run build diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 63e4b4de..9cc66af2 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -10,7 +10,7 @@ jobs: fail-fast: false matrix: node-version: [18.x, 20.x, 21.x] - os: [ubuntu-latest, debian-latest, windows-latest, macos-latest] + os: [ubuntu-latest, windows-latest, macos-latest] steps: - uses: actions/checkout@v4