From e706622db55d542d362a39935bb3be71c56533cb Mon Sep 17 00:00:00 2001 From: Ayush3603 Date: Mon, 10 Nov 2025 22:02:17 +0530 Subject: [PATCH] feat: add environment configuration template (.env.example) --- .env.example | 74 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 .env.example diff --git a/.env.example b/.env.example new file mode 100644 index 00000000..98754ef6 --- /dev/null +++ b/.env.example @@ -0,0 +1,74 @@ +# Umami Environment Configuration Template +# Copy this file to .env and update with your actual values + +# ============================================ +# REQUIRED CONFIGURATION +# ============================================ + +# Database Configuration (Required) +# PostgreSQL connection string (minimum version 12.14) +# Format: postgresql://username:password@host:port/database +# Example: postgresql://umami:mypassword@localhost:5432/umami +DATABASE_URL=postgresql://username:password@localhost:5432/umami + +# ============================================ +# OPTIONAL CONFIGURATION +# ============================================ + +# Base Path +# If you want to host Umami under a subdirectory (e.g., /analytics) +# Leave empty for root path deployment +# BASE_PATH=/analytics + +# Tracker Script Customization +# Comma-separated list of alternative names for the tracking script +# Useful for avoiding ad blockers +# TRACKER_SCRIPT_NAME=custom-script.js,analytics.js + +# Tracker Script URL +# External URL for the tracker script if hosted separately +# TRACKER_SCRIPT_URL=https://example.com/script.js + +# Collection API Endpoint +# Custom endpoint for collecting analytics data +# COLLECT_API_ENDPOINT=/api/collect + +# CORS Configuration +# Maximum age for CORS preflight requests (in seconds) +# CORS_MAX_AGE=86400 + +# Localization +# Default locale for the application +# DEFAULT_LOCALE=en-US + +# Security +# Force SSL/HTTPS connections +# FORCE_SSL=1 + +# Frame Ancestors +# Allowed URLs that can embed Umami in an iframe (space-separated) +# ALLOWED_FRAME_URLS=https://example.com https://another.com + +# Cloud Mode (Umami Cloud only) +# Enable cloud mode features +# CLOUD_MODE=1 +# CLOUD_URL=https://cloud.umami.is +# CLICKHOUSE_URL=https://clickhouse.example.com +# REDIS_URL=redis://localhost:6379 + +# Database Type Override +# Skip database checks if using alternative database setup +# DATABASE_TYPE=custom + +# Skip Checks (Development only) +# Skip database checks during development +# SKIP_DB_CHECK=1 +# SKIP_DB_MIGRATION=1 + +# ============================================ +# NOTES +# ============================================ +# 1. Never commit the .env file to version control +# 2. After first build, change the default admin password (admin/umami) +# 3. Ensure PostgreSQL is running before starting the application +# 4. For production, always use strong passwords and enable FORCE_SSL