-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #5 from marmelab/features/supabase
replace postgrest docker-compose with supabase
- Loading branch information
Showing
15 changed files
with
1,636 additions
and
188 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,4 @@ | ||
# Configure your dev environment | ||
DATABASE_PORT=<wanted postgres database port> | ||
DATABASE_USER=<wanted postgres database username> | ||
DATABASE_PASSWORD=<wanted postgres database password> | ||
|
||
DATABASE_NAME=connect_four_reboot_admin | ||
PGRST_DB_ANON_ROLE=web_anon | ||
PGRST_DB_SCHEMA=public | ||
## Please update those values if you modify the supabase default configuration | ||
SUPABASE_DB_URL=postgresql://postgres:postgres@127.0.0.1:54322/postgres ## supabase default url | ||
VITE_SUPABASE_URL= http://127.0.0.1:54321 ## supabase url for react admin dataprovider | ||
VITE_SUPABASE_API_KEY= eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZS1kZW1vIiwicm9sZSI6ImFub24iLCJleHAiOjE5ODM4MTI5OTZ9.CRXP1A7WOeoJeXxjNni43kdQwgnWNReilDMblYTn_I0 ## please put your supabase anon key |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
name: Deploy to prod | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
deploy: | ||
runs-on: ubuntu-latest | ||
environment: production | ||
permissions: | ||
pages: write | ||
id-token: write | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Set up Node.js | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: "20" | ||
|
||
- name: Install dependencies | ||
run: npm install | ||
|
||
- name: Build the app | ||
env: | ||
VITE_SUPABASE_URL: ${{ secrets.VITE_SUPABASE_API_URL }} | ||
VITE_SUPABASE_ANON_KEY: ${{ secrets.VITE_SUPABASE_ANON_KEY }} | ||
run: npm run build | ||
|
||
- name: Link Supabase && init db && populate | ||
env: | ||
SUPABASE_PROJECT_REF: ${{ vars.SUPABASE_PROJECT_REF }} | ||
SUPABASE_ACCESS_TOKEN: ${{ secrets.SUPABASE_ACCESS_TOKEN }} | ||
SUPABASE_DB_URL: ${{ secrets.SUPABASE_DB_URL }} | ||
run: | | ||
npx supabase link --project-ref $SUPABASE_PROJECT_REF | ||
npx tsx tools/populateDbWithFakeData.ts | ||
- name: Upload to GitHub Pages | ||
uses: actions/upload-pages-artifact@v3 | ||
with: | ||
path: dist | ||
|
||
- name: 🚀 Deploy to github pages | ||
uses: actions/deploy-pages@v4 |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
name: CI | ||
name: CI tests | ||
|
||
on: | ||
push: | ||
|
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
This file was deleted.
Oops, something went wrong.
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
Oops, something went wrong.