FastStarter
  • Introduction
  • Guide
    • CodeSetup
    • DataBaseSetup
    • AuthSetup
    • StorageSetup
    • FeaturePageSetup
    • FeatureAPISetup
    • PaymentSetup
    • PricingPageSetup
    • HeaderSetup
    • HomePageSetup
    • PrivacyPageSetup
    • DeploySetup
    • DNSSetup
    • AnalyticsSetup
    • MultipleLanguages
  • Introduction
  • Guide
    • CodeSetup
    • DataBaseSetup
    • AuthSetup
    • StorageSetup
    • FeaturePageSetup
    • FeatureAPISetup
    • PaymentSetup
    • PricingPageSetup
    • HeaderSetup
    • HomePageSetup
    • PrivacyPageSetup
    • DeploySetup
    • DNSSetup
    • AnalyticsSetup
    • MultipleLanguages

On This Page

  • Base key
  • Google Auth
Guide
AuthSetup

AuthSetup

use next-auth https://next-auth.js.org/ (opens in a new tab)

Base key

openssl rand -base64 32

This generates a 32-byte random string to use as Auth Secret

NEXTAUTH_SECRET=

Google Auth

https://console.cloud.google.com/apis/dashboard (opens in a new tab)

https://developers.google.com/identity/protocols/oauth2?hl=zh-cn (opens in a new tab)

set redirects url [base_url]/api/auth/callback/google

get client_id & client_secret

Set Google key

GOOGLE_CLIENT_ID= GOOGLE_CLIENT_SECRET=

DataBaseSetupStorageSetup

FastStarter Docs