build: swap to oxlint #1568
Workflow file for this run
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: smoke | |
| on: | |
| pull_request: | |
| push: | |
| branches: | |
| - master | |
| jobs: | |
| smoke: | |
| # Running smoke tets requires direct access to imagery inside of s3://linz-basemaps | |
| # which no other repository should have | |
| # | |
| # As the workflow can be run from either a push or a pull request, it needs to check that | |
| # 1. the push is directly to linz/basemaps | |
| # 2. pull request originated from 'linz/basemaps' | |
| if: | | |
| (github.event_name == 'push' && github.repository == 'linz/basemaps') || | |
| (github.event.pull_request.head.repo.full_name == 'linz/basemaps') | |
| runs-on: ubuntu-latest | |
| environment: | |
| name: preprod | |
| permissions: | |
| id-token: write | |
| contents: read | |
| steps: | |
| - uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 0 | |
| - uses: actions/[email protected] | |
| with: | |
| node-version-file: .node-version | |
| - run: npm ci | |
| - run: npm run build | |
| - run: npm run check | |
| - run: npm run test | |
| # Package all the files | |
| - name: Bundle & Package all files | |
| run: | | |
| npx lerna run bundle --stream | |
| npm pack --workspaces | |
| env: | |
| NODE_ENV: 'production' | |
| - name: (NonProd) Configure AWS Credentials | |
| uses: aws-actions/[email protected] | |
| with: | |
| aws-region: ap-southeast-2 | |
| mask-aws-account-id: true | |
| role-to-assume: ${{ secrets.AWS_ROLE_SCREENSHOT }} | |
| - name: (Smoke) Run Smoke Tests | |
| run: | | |
| # Copy the static files for v1/health check | |
| cp -r packages/lambda-tiler/static/ . | |
| ./packages/server/bin/basemaps-server.cjs --config s3://linz-basemaps/config/config-latest.json.gz & | |
| # Wait for the server to start | |
| timeout 30 bash -c 'while [[ "$(curl -s -o /dev/null -w ''%{http_code}'' http://localhost:5000/v1/version)" != "200" ]]; do sleep 0.5; done' || false | |
| BASEMAPS_HOST=http://localhost:5000 node --test packages/smoke/build/*.test.js | |
| env: | |
| GIT_VERSION: $(git describe --tags --always --match 'v*') | |
| GIT_HASH: $(git rev-parse HEAD) |