fix: package.json to reduce vulnerabilities #1030
This file contains 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: | |
push: | |
branches-ignore: | |
- main | |
- development | |
pull_request: | |
branches-ignore: | |
- main | |
- development | |
jobs: | |
test: | |
runs-on: ${{ matrix.os }} | |
timeout-minutes: 15 | |
strategy: | |
matrix: | |
os: [ ubuntu-latest ] | |
node: [ 16.13 ] | |
mongodb: [ 4.4 ] | |
env: | |
ORIGIN: http://localhost:3000 | |
MONGO_URL: mongodb://localhost:27017/test | |
AIRTABLE_URL: airtableUrl | |
AIRTABLE_API_KEY: airtableKey | |
JWT_HTTPS: false | |
JWT_SECRET: hard!to-guess_Secret | |
JWT_TIME_TO_LIVE: 604800000 | |
services: | |
mongodb: | |
image: mongo:4.4 | |
options: >- | |
--health-cmd mongo | |
--health-interval 10s | |
--health-timeout 5s | |
--health-retries 5 | |
ports: | |
- 27017:27017 | |
steps: | |
- name: Checkout π | |
uses: actions/checkout@v3.0.2 | |
- name: Setup node env π | |
uses: actions/setup-node@v3.1.1 | |
with: | |
node-version: ${{ matrix.node }} | |
cache: 'yarn' | |
- name: Install dependencies π¨π»βπ» | |
run: yarn install --frozen-lockfile | |
- name: Run tests π§ͺ | |
run: yarn test:ci | |
# - name: Run linter π | |
# run: yarn lint | |
- name: Upload test artifacts 𦴠| |
uses: actions/upload-artifact@v3 | |
if: success() || failure() | |
with: | |
name: test-results-${{ matrix.os }} | |
path: reports/jest-*.xml | |
- name: Report code coverage π | |
continue-on-error: true | |
uses: romeovs/lcov-reporter-action@v0.3.1 | |
with: | |
lcov-file: coverage/lcov.info | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
build: | |
runs-on: ${{ matrix.os }} | |
timeout-minutes: 15 | |
strategy: | |
matrix: | |
os: [ ubuntu-latest,windows-latest,macos-latest ] | |
node: [ 16.13 ] | |
steps: | |
- name: Checkout π | |
uses: actions/checkout@v3.0.2 | |
- name: Setup node env π | |
uses: actions/setup-node@v3.1.1 | |
with: | |
node-version: ${{ matrix.node }} | |
cache: 'yarn' | |
- name: Install dependencies π¨π»βπ» | |
run: yarn install --frozen-lockfile | |
- name: Building project π§ | |
run: yarn build |