devops #16
Workflow file for this run
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: | |
pull_request: ~ | |
push: | |
branches: | |
- master | |
- releases/* | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
name: Run eslint/format | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: '19.x' | |
# cache: yarn | |
# cache-dependency-path: './apps/web/package-lock.json' | |
- name: Install yarn | |
run: npm install -g yarn | |
- name: Install dependencies | |
run: yarn install | |
- name: Lint web | |
run: yarn lint | |
- name: Prettier | |
run: yarn format | |
tsc: | |
runs-on: ubuntu-latest | |
name: Check tsc | |
needs: [lint] | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: '19.x' | |
# cache: yarn | |
# cache-dependency-path: './apps/web/package-lock.json' | |
- name: Install yarn | |
run: npm install -g yarn | |
- name: Install dependencies | |
run: yarn install | |
- name: tsc | |
run: yarn tsc | |
jest: | |
runs-on: ubuntu-latest | |
name: Run tests on server | |
needs: [lint, tsc] # ensure tests are run only after eslint and tsc pass | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: '19.x' | |
# cache: yarn | |
# cache-dependency-path: './apps/server/package-lock.json' | |
- name: Install yarn | |
run: npm install -g yarn | |
- name: Install dependencies | |
run: yarn install | |
- name: Test server | |
run: yarn test |