Notra Logo
Notra

Deploy

Vercel Deployment Steps

1 Start Deployment

Click https://vercel.com/new/clone?repository-url=https://github.com/Levix0501/notra&env=NEXT_PUBLIC_LOCALE,AUTH_SECRET,DATABASE_URL,DIRECT_URL,SUPABASE_URL,SUPABASE_API_KEY&project-name=notra&repository-name=notra to start deployment.

image

Log in to Vercel, it is recommended to log in with a Github account.

image

Click Create

image

2 Environment Variables

2.1 NEXT_PUBLIC_LOCALE (Optional)

Used to set the website language, options: en, zh

image

Currently supported languages: English (en), Simplified Chinese (zh).

2.2 AUTH_SECRET (Required)

AUTH_SECRET is a core security key in Auth.js.It is mainly used for encryption and signing, ensuring user identity and session security.

image

You can generate it online using an existing third-party tool:

  1. Visit: https://jwtsecrets.com/#generator

  2. Click Generate

  3. Copy the key

image

2.3 Other Environment Variables

DATABASE_URL, DIRECT_URL, SUPABASE_URL, and SUPABASE_API_KEY — the usage and retrieval methods of these four environment variables will be introduced in the next section.

3 Supabase

Supabase provides a PostgreSQL-based database and object storage (used to store images and other files), making it convenient to quickly build the core data and file management capabilities of your application.

3.1 Create a Project

Visit: https://supabase.com/

image

Click Start your project

image

Log in to Supabase (recommended to log in with a Github account). After logging in, visit: https://supabase.com/dashboard/new

image

Click Create organization

image

Follow these steps:

  1. Enter Project name

  2. Click Generate a password to generate a database password

  3. Click Copy to copy the password and save it locally for later use

  4. Choose a region (recommended: West US (North California))

  5. Click Create new project

3.2 DATABASE_URL & DIRECT_URL

image

Click Connect

image

In the pop-up dialog, select ORMs, then replace [YOUR-PASSWORD] in DATABASE_URL and DIRECT_URL with your database password. Enter them into the Vercel environment variables.

image

3.3 SUPABASE_URL

Click Project Settings

image

Click Data API

image

Copy Project URL

image

Enter it into SUPABASE_URL

image

3.4 SUPABASE_API_KEY

image
  1. Click API Keys

  2. Select API Keys

  3. Click Create new API keys

image

In the pop-up dialog, click Create keys

image

Copy the API KEY

image

Enter it into SUPABASE_API_KEY

4 Deployment

image

After filling in all the environment variables as described above, click Deploy

image

After a successful deployment, click Continue to Dashboard.

image

Visit the domain automatically assigned by Vercel to access your personal website.
You can also set up a custom domain.