Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ausminternet/remix-pocketbase-starter
Example app with complete server side registration and authentication flow (including OAuth), using Remix and PocketBase
https://github.com/ausminternet/remix-pocketbase-starter
Last synced: 14 days ago
JSON representation
Example app with complete server side registration and authentication flow (including OAuth), using Remix and PocketBase
- Host: GitHub
- URL: https://github.com/ausminternet/remix-pocketbase-starter
- Owner: ausminternet
- License: mit
- Created: 2023-12-14T20:19:22.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2023-12-16T20:15:43.000Z (about 1 year ago)
- Last Synced: 2024-09-26T02:01:28.577Z (4 months ago)
- Language: TypeScript
- Size: 247 KB
- Stars: 30
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-pocketbase - GitHub
- awesome-pocketbase - GitHub
README
# Remix + PocketBase
Example app with complete server side registration and authentication flow (including OAuth), using Remix and PocketBase. PocketBase is not exposed to the client.
Used technologies:
- App: [Remix](https://remix.run)
- BaaS: [PocketBase](https://pocketbase.io)
- UI: [DaisyUI](https://daisyui.com/)Demo: [https://remixpb.uber.space](https://remixpb.uber.space)
## Usage
Install and run [Pocketbase](https://pocketbase.io/) or create a hosted instance on [pockethost.io](https://pockethost.io) and enter your pocketbase url in your `.env`:
```env
POCKETBASE_URL=http://localhost:8090
```Open the PocketBase admin ui and go to *Settings* > *Application* and change the *Application URL* to your app url (`http://localhost.3000` for Example).
Go to *Collections* > *Users* > *Edit Collection* > *Options* and activate *Forbid authentication for unverified users*.
Then got to *Settings* > *Mail Settings* and change the following action URLs:
- Verification: `{APP_URL}/auth/confirm-verification?token={TOKEN}`
- Password reset: `{APP_URL}/auth/confirm-password-reset?token={TOKEN}`
- Confirm email change: `{APP_URL}/auth/confirm-email-change?token={TOKEN}`To use authentication via OAuth providers, go to *Settings* > *Auth Providers* and configure the desired providers.
Additionally you have to add the correct OAuth callback url in your `.env`:
```env
OAUTH_CALLBACK_URL=http://localhost:3000/auth/oauth-callback
```After you have set up your PocketBase and populated the `.env` file, clone this repository, install dependencies and run the remix app:
```bash
git clone https://github.com/ausminternet/remix-pocketbase-starter
pnpm install
pnpm run dev```