Skip to content

Environment Variables

This page provides a comprehensive reference for the environment variables used in the backend and frontend projects. These are configured in the .env file for local development and in the Cloudflare Pages dashboard for production and staging environments.

These variables are defined in the .env file within the backend directory and are used by the Docker Compose services.

  • GPG_PASSPHRASE The passphrase used to encrypt and decrypt the nightly database backups.
  • PORTAINER_PASSWORD The admin password for the Portainer dashboard.
  • TZ Sets the system timezone for all services. Default: Asia/Kolkata.
  • KEY & SECRET Unique, random strings used by Directus for security, including authentication and encryption.
  • ADMIN_EMAIL & ADMIN_PASSWORD The credentials for the default administrative user in Directus.
  • PUBLIC_URL The primary, public-facing URL where the Directus API can be accessed. Example: https://admin.innovspatial.com.
  • TURNSTILE_SECRET_KEY The secret key for Cloudflare Turnstile (a CAPTCHA alternative) to protect public-facing forms.
  • MAX_PAYLOAD_SIZE The maximum size for API request payloads. Default: 10mb.
  • FLOWS_ENV_ALLOW_LIST A comma-separated list of environment variables that should be accessible within Directus Flows.
  • POSTGRES_DB, POSTGRES_USER, POSTGRES_PASSWORD Core credentials for the PostgreSQL server itself.
  • DB_CLIENT Specifies the database client. Set to pg for PostgreSQL.
  • DB_HOST, DB_PORT, DB_DATABASE, DB_USER, DB_PASSWORD Connection details specifically for the directus database. These often reference the main PostgreSQL credentials.
  • DB_POOL_MIN & DB_POOL_MAX The minimum and maximum number of connections to keep in the database connection pool.
  • CACHE_ENABLED Whether to enable the internal Directus cache. Default: true.
  • CACHE_TTL The default Time-To-Live for cached items in seconds. Default: 86400 (1 day).
  • CACHE_CONTROL_S_MAXAGE The s-maxage value for the Cache-Control header, used by shared caches like CDNs. Default: 2592000 (30 days).
  • STORAGE_LOCATIONS Defines the storage adapters. Default: local.
  • STORAGE_LOCAL_ROOT The root directory for local file storage. Default: ./uploads.
  • EMAIL_FROM The default “from” address for emails sent by Directus.
  • EMAIL_TRANSPORT, EMAIL_SMTP_HOST, etc. Configuration for the SMTP service used to send transactional emails.
  • ADMIN_USER_EMAIL, ADMIN_USER_NAME, ADMIN_USER_PWD Credentials for the initial administrative user for the Plausible dashboard.
  • BASE_URL The public-facing URL for the Plausible Analytics dashboard. Example: https://analytics.innovspatial.com.
  • SECRET_KEY_BASE A unique secret key for securing the Plausible instance.
  • DATABASE_URL The connection string for the Plausible PostgreSQL database.
  • CLICKHOUSE_DATABASE_URL The connection string for the ClickHouse events database.
  • NETDATA_CLAIM_TOKEN & NETDATA_CLAIM_ROOMS Credentials for claiming the Netdata agent and associating it with your Netdata Cloud account.
  • NETDATA_CLAIM_URL The URL for the Netdata Cloud claiming service.

These variables are configured directly in the Cloudflare Pages dashboard for each frontend project (innovspatial and hawaii).

  • DIRECTUS_STATUS_FILTER Controls which items are fetched from Directus based on their status.
    • Production (main branch): Set to published.
    • Staging (staging branch): Set to draft,published.