Skip to content

Commit

Permalink
Update docs/self-hosting/server-database.mdx (lobehub#4467)
Browse files Browse the repository at this point in the history
  • Loading branch information
MrChrisRodriguez authored Oct 24, 2024
1 parent 7ef2c82 commit 9fb2641
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions docs/self-hosting/server-database.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ tags:
- Postgres
- Deployment Guide
---

# Deploying Server-Side Database

LobeChat defaults to using a client-side database (IndexedDB) but also supports deploying a server-side database. LobeChat uses Postgres as the backend storage database.
Expand Down Expand Up @@ -97,7 +98,10 @@ In the server-side database mode, we need an authentication service to distingui

[Clerk](https://clerk.com?utm_source=lobehub&utm_medium=docs) is an authentication SaaS service that provides out-of-the-box authentication capabilities with high productization, low integration costs, and a great user experience. For those who offer SaaS products, Clerk is a good choice. Our official [LobeChat Cloud](https://lobechat.com) uses Clerk as the authentication service.

The integration of Clerk is relatively simple, requiring only the configuration of the `NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY`, `CLERK_SECRET_KEY`, and `CLERK_WEBHOOK_SECRET` environment variables, which can be obtained from the Clerk console.
The integration of Clerk is relatively simple, requiring only the configuration of these environment variables:

- `NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY` and `CLERK_SECRET_KEY`, which can be obtained from the Clerk console
- `CLERK_WEBHOOK_SECRET`, which is generated by following these instructions: [Configure Clerk Authentication Service](/docs/self-hosting/advanced/auth/clerk#create-and-configure-webhook-in-clerk).

<Callout type={'tip'}>
In Vercel deployment mode, we recommend using Clerk as the authentication service for a better user experience.
Expand Down Expand Up @@ -137,4 +141,4 @@ For detailed configuration guidelines on S3, please refer to [S3 Object Storage]

The above is a detailed explanation of configuring LobeChat with a server-side database. You can configure it according to your actual situation and then choose a deployment platform that suits you to start deployment:

<PlatformCards urlPrefix={'server-database'} />
<PlatformCards urlPrefix={'server-database'} />

0 comments on commit 9fb2641

Please sign in to comment.