Update .env.example to use relative URL '/' as default for NEXT_PUBLIC_BASE_URL

This ensures the API uses the same protocol and domain as the frontend,
preventing mixed content blocking in staging/production environments.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
This commit is contained in:
2026-03-12 12:06:16 +08:00
parent c6c3eebadf
commit 2108f403aa

View File

@@ -12,10 +12,12 @@ WIBU_UPLOAD_DIR=uploads
WIBU_DOWNLOAD_DIR=./download
# Application Configuration
# For local development: NEXT_PUBLIC_BASE_URL=http://localhost:3000
# For staging/production: Set to your actual domain (e.g., https://your-domain.com)
# Using relative URL '/' is recommended for deployment flexibility
NEXT_PUBLIC_BASE_URL=http://localhost:3000
# IMPORTANT: For staging/production, set this to your actual domain
# Local development: NEXT_PUBLIC_BASE_URL=http://localhost:3000
# Staging: NEXT_PUBLIC_BASE_URL=https://desa-darmasaba-stg.wibudev.com
# Production: NEXT_PUBLIC_BASE_URL=https://your-production-domain.com
# Or use relative URL '/' for automatic protocol/domain detection (recommended)
NEXT_PUBLIC_BASE_URL=/
# Email Configuration (for notifications/subscriptions)
EMAIL_USER=your_email@gmail.com