Skip to content

♻️ Require auth for self hosters with app router (#938) #9

♻️ Require auth for self hosters with app router (#938)

♻️ Require auth for self hosters with app router (#938) #9

Workflow file for this run

name: CI
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
linting:
name: Linting
runs-on: ubuntu-latest
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ secrets.TURBO_TEAM }}
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Setup node
uses: actions/setup-node@v3
with:
node-version: 18
cache: yarn
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Check linting rules
run: yarn lint
- name: Check types
run: yarn lint:tsc
# Label of the container job
integration-tests:
name: Run tests
# Containers must run in Linux based operating systems
runs-on: ubuntu-latest
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ vars.TURBO_TEAM }}
steps:
# Downloads a copy of the code in your repository before running CI tests
- name: Check out repository code
uses: actions/checkout@v3
- name: Install system dependencies
run: |
sudo apt-get update
- name: Setup node
uses: actions/setup-node@v3
with:
node-version: 18
cache: yarn
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Set environment variables
run: |
echo "DATABASE_URL=postgresql://postgres:password@localhost:5450/db" >> $GITHUB_ENV
- name: Run db
run: |
docker pull postgres:14.2
docker run -d -p 5450:5432 -e POSTGRES_PASSWORD=password -e POSTGRES_DB=rallly postgres:14.2
yarn wait-on --timeout 60000 tcp:localhost:5450
- name: Deploy migrations
run: yarn db:setup
- name: Install playwright dependencies
run: yarn playwright install --with-deps chromium
- name: Run tests
run: yarn test
- name: Upload artifact playwright-report
if: ${{ success() || failure() }}
uses: actions/upload-artifact@v3
with:
name: playwright-report
path: ./apps/web/playwright-report