-
Notifications
You must be signed in to change notification settings - Fork 15
Environment Variables
The .env
file is used to configure the application. Below is a detailed explanation of the environment variables required for the application to function properly.
The .env.example
file contains a complete list of variables to help you set up your environment. You can download and rename it as .env
.
All variables must be provided unless explicitly marked as optional.
- Description: The base URL of your site.
-
Default:
http://localhost:3000
-
Usage: Set this to your domain URL without a trailing slash. Examples:
SITE_URL=https://www.yourdomain.com
SITE_URL=http://192.168.1.100
-
SITE_URL=http://test.local:3000
(with port numbers if applicable)
- Description: The name of the PostgreSQL database.
-
Default:
wapydev
- Description: The username for the PostgreSQL database.
-
Default:
wapydev
- Description: The password for the PostgreSQL database.
-
Default: Automatically generated by the
./scripts/setup.sh
script if not provided. -
Guide: Run
openssl rand -base64 32
to generate a secure password.
- Description: The connection URL for the PostgreSQL database.
-
Default: Pre-configured based on the default
docker-compose.yml
setup.
The following variables are used to configure the email server for handling authentication emails, email notifications and contact form submissions.
- Description: The username for the email server.
- Default: None
- Description: The password for the email server.
- Default: None
- Description: The hostname of the email server.
- Default: None
-
Example:
smtp.example.com
- Description: The port used by the email server.
-
Default:
587
(commonly used for SMTP with STARTTLS) -
Example:
465
(commonly used for SMTP with SSL)
- Description: The email address used as the sender for outgoing emails.
- Default: None
-
Example:
[email protected]
- Description: The email address where contact form submissions will be sent.
- Default: None
-
Example:
[email protected]
The following variables are used to configure the authentication system.
- Description: The secret key used for authentication. This is critical for securing user sessions.
-
Default: Automatically generated by the
./scripts/setup.sh
script if not provided. -
Example:
a1b2c3d4e5f6g7h8i9j0
-
Guide: Run
openssl rand -base64 32
to generate a secure password.
-
Description: Determines whether to trust the
Host
header in the authentication process. -
Default:
true
-
Example:
true
orfalse
-
Description: The URL of the authentication endpoint. This is automatically derived from the
SITE_URL
variable. -
Default:
${SITE_URL}/api/auth
- Note: There is no need to change this value unless you have a custom setup.
-
Description: The URL of the authentication endpoint. This is automatically derived from the
SITE_URL
variable. -
Default:
false
-
Example:
true
orfalse
- Guide: Disable New User Registration
The following variables are optional and only required if you want to enable Github login for your application.
- Description: The client ID for the Github OAuth application.
- Default: None
- Guide: How to register your Github app
- Description: The client secret for the Github OAuth application.
- Default: None
- Guide: How to register your Github app
The following variables are optional and only required if you want to enable Google login for your application.
- Description: The client ID for the Google OAuth application.
- Default: None
- Description: The client secret for the Google OAuth application.
- Default: None
The following variables are required if you want to enable Keycloak login for your application.
- Description: The client ID for the Keycloak OAuth2/OpenID client.
- Default: None
- Guide: Integration guide and Keycloak documentation
- Description: The client secret for the Keycloak OAuth2/OpenID client.
- Default: None
- Guide: Integration guide and Keycloak documentation
-
Description: The issuer URL of the Keycloak realm.
Must include the realm name, e.g.http://localhost:8080/realms/myrealm
. - Default: None
- Guide: Integration guide and Keycloak documentation
The following variables are required if you want to enable Authentik login for your application.
- Description: The client ID for the Authentik OAuth2/OpenID application.
- Default: None
- Guide: Integration guide and Authentik application setup
- Description: The client secret for the Authentik OAuth2/OpenID application.
- Default: None
- Guide: Integration guide and Authentik application setup
-
Description: The issuer URL for your Authentik provider.
Typically looks likehttp://localhost:9000/application/o/<slug>/
. - Default: None
- Guide: Integration guide and Authentik provider configuration
The following variables are optional and only required if you want to enable push notifications for your application.
- Description: The public key for the Web Push API, used to send push notifications to users.
-
Default: Automatically generated by the
./scripts/setup.sh
script if not provided. -
Guide: Run
npx --yes web-push generate-vapid-keys --json
to generate keys and copypublicKey
field.
- Description: The private key for the Web Push API, used to authenticate push notifications.
-
Default: Automatically generated by the
./scripts/setup.sh
script if not provided. -
Guide: Run
npx --yes web-push generate-vapid-keys --json
to generate keys and copyprivateKey
field.
The following variable is required for signing subscription-related data.
- Description: The secret key used for signing subscription-related JWTs (JSON Web Tokens).
-
Default: Automatically generated by the
./scripts/setup.sh
script if not provided. -
Guide: Run
openssl rand -base64 32
to generate a secure password.
Getting Started
Learn how to install the application with Docker.
Environment Variables
Learn how to configure the application.
Single Sign-On (SSO) Alternatives
Find detailed instructions on how to configure login with Keycloak or Authentik.
Self‐Hosting without SMTP Email Server
Find detailed instructions on how to set up and configure Mailpit as a local SMTP server for self-hosted environments.
Webhook Integration
Find detailed instructions on how to use webhook.
Disable New User Registration
Learn how to disable new user registration.
Building Docker Image
Learn how to build the Docker image locally.
Database Backup and Restore
Find detailed instructions on how to back up and restore the database, including automation tips.