diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 93218b3..afc6a86 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -2,16 +2,18 @@ name: ci on: push: - branches: [$default-branch] + branches: + - master pull_request: - branches: [$default-branch] + branches: + - master jobs: build: - runs-on: ubuntu-18.04 + runs-on: ubuntu-22.04 strategy: matrix: - node-version: [14.x, 16.x, 17.x, 18.x] + node-version: [14.x, 16.x, 18.x] steps: - uses: actions/checkout@v2 - name: Use Node.js ${{ matrix.node-version }} @@ -20,23 +22,22 @@ jobs: node-version: ${{ matrix.node-version }} - name: Install dependencies run: | - sudo add-apt-repository -y ubuntu-toolchain-r-test - sudo apt-get -y update - sudo apt-get install -y python3 make g++-4.8 - - run: npm ci - - run: npm test + sudo apt-get install -y python3 make g++ + - name: Test + run: npm test build-alpine: - runs-on: ubuntu-18.04 + runs-on: ubuntu-22.04 strategy: matrix: - node-version: [14, 16, 17, 18] + node-version: [14, 16, 18] container: image: node:${{ matrix.node-version }}-alpine steps: - uses: actions/checkout@v2 - name: Install dependencies run: | - apk add make g++ python - - run: npm ci --unsafe-perm - - run: npm test --unsafe-perm + apk add make g++ python3 + - name: Test + run: | + npm test --unsafe-perm diff --git a/package.json b/package.json index 32d177f..19a8f3b 100644 --- a/package.json +++ b/package.json @@ -25,7 +25,7 @@ "url": "https://github.com/kelektiv/node.bcrypt.js/issues" }, "scripts": { - "test": "npm install --build-from-source && nodeunit test", + "test": "npm ci --build-from-source && nodeunit test", "install": "node-pre-gyp install --fallback-to-build" }, "dependencies": { @@ -64,4 +64,4 @@ 3 ] } -} +} \ No newline at end of file