Merge pull request #5 from zaproxy/dependabot/npm_and_yarn/ejs-6.0.1 #20
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| pull_request: | |
| push: | |
| branches: [main] | |
| permissions: | |
| contents: read | |
| concurrency: | |
| group: ci-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| node: | |
| name: Node boot + smoke | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-node@v6 | |
| with: | |
| node-version: '22' | |
| cache: 'npm' | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Boot server and run smoke test | |
| run: | | |
| set -euo pipefail | |
| node server.js & | |
| PID=$! | |
| trap "kill $PID 2>/dev/null || true" EXIT | |
| bash scripts/smoke.sh | |
| docker: | |
| name: Docker build + smoke | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v4 | |
| - name: Build image | |
| uses: docker/build-push-action@v7 | |
| with: | |
| context: . | |
| load: true | |
| tags: crawlground:ci | |
| cache-from: type=gha | |
| cache-to: type=gha,mode=max | |
| - name: Run container and smoke test | |
| run: | | |
| set -euo pipefail | |
| docker run -d --rm --name ctr -p 3456:3456 crawlground:ci | |
| trap "docker stop ctr 2>/dev/null || true" EXIT | |
| bash scripts/smoke.sh |