-
Notifications
You must be signed in to change notification settings - Fork 0
51 lines (42 loc) · 1.13 KB
/
ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
---
name: Continuous Integration
on:
push:
branches:
- main
pull_request:
branches:
- main
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: read
pull-requests: read
env:
SUPABASE_PROJECT_ID: ${{ secrets.SUPABASE_PROJECT_ID }}
SUPABASE_ACCESS_TOKEN: ${{ secrets.SUPABASE_ACCESS_TOKEN }}
SUPABASE_DB_PASSWORD: ${{ secrets.SUPABASE_PASSWORD }}
FORCE_COLOR: 1
jobs:
ci:
runs-on: self-hosted
timeout-minutes: 5
steps:
- name: 📦 Checkout Repository
uses: actions/checkout@v4
- name: 🛠️ Setup Biome
uses: biomejs/setup-biome@v2
- name: 🚀 Run Biome
run: biome ci
- if: github.ref == 'refs/heads/main'
name: 🚀 Setup Supabase CLI
uses: supabase/setup-cli@v1
with:
version: latest
- if: github.ref == 'refs/heads/main'
name: 🚀 Deploy migrations
continue-on-error: true
run: |
supabase link --project-ref ${{ env.SUPABASE_PROJECT_ID }}
supabase db push --include-all -p ${{ env.SUPABASE_DB_PASSWORD }}