Skip to content

Commit

Permalink
Adding GitHub checks
Browse files Browse the repository at this point in the history
Co-authored-by: MayanjaAndrew <68685849+MayanjaAndrew@users.noreply.github.com>
  • Loading branch information
gitstart and MayanjaAndrew committed Jun 29, 2023
1 parent d9247b8 commit cee2f4c
Showing 1 changed file with 59 additions and 0 deletions.
59 changes: 59 additions & 0 deletions .github/workflows/checks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
name: CI/CD Checks

on:
push:
branches: [main]
pull_request:

jobs:
format-check:
runs-on: ubuntu-latest

steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Setup environment (node, npm install)
uses: ./.github/actions/setup
- name: Format check
run: npm run format:check

build-check:
runs-on: ubuntu-latest

steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Setup environment (node, npm install)
uses: ./.github/actions/setup
- name: Build check
run: npm run build

server-test:
services:
postgres:
image: postgres
env:
POSTGRES_PASSWORD: pg
POSTGRES_DB: flow_test
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 5432:5432

runs-on: ubuntu-latest
timeout-minutes: 5
env:
DATABASE_URL: postgresql://postgres@localhost:5432/flow

steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Setup environment (node, npm install)
uses: ./.github/actions/setup
- name: Prisma Gen
run: npm run gen -w apps/server
- name: Test check
run: npm run test -w apps/server

0 comments on commit cee2f4c

Please sign in to comment.