diff --git a/.env-template b/.env-template index 3cf86cfe..62b4769f 100644 --- a/.env-template +++ b/.env-template @@ -1,23 +1,61 @@ +# =========== +# This environment variable template is the canonical source for all environment variables used by PocketHost. +# PocketHost relies upon environment variables rather than prop drilling where possible. +# =========== + + # This is the porject root (where the .env file lives) ROOT="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" # Do this so these actually export as environment variables, not just shell variables set -a +# ============== +# PUBLIC variables are available and visible to the frontends +# The defaults shown here will invoke LOCAL development modes. If they are not specified, +# the frontends will default to the production environment. +# +# To create prduction builds, simply omit these, or if you have a special need, supply +# the custom values here. +# ============== + + +# The global debugging flag, used by frontend and backend. This will enable debug-level +# logging on all fronts +PUBLIC_DEBUG=true + # https or http, as you wish PUBLIC_HTTP_PROTOCOL=https +# The apex domain for the whole site. +PUBLIC_APEX_DOMAIN=pockethost.lvh.me + + +#-------------- +# You typically won't need to change these, unless you have a very specific setup +# https:// - marketing/lander +# https://app. - dashboard +# https://pockethost-central. - mothership +# https://*.edge. - edge workers +#-------------- + # The domain name the dashboard app -PUBLIC_APP_DOMAIN=app.pockethost.lvh.me +PUBLIC_APP_DOMAIN=app.$PUBLIC_APEX_DOMAIN # The domain name for the marketing/blog domain -PUBLIC_BLOG_DOMAIN=pockethost.lvh.me +PUBLIC_BLOG_DOMAIN=$PUBLIC_APEX_DOMAIN # The apex domain for the daemon -PUBLIC_EDGE_APEX_DOMAIN=pockethost.io +PUBLIC_EDGE_APEX_DOMAIN=edge.$PUBLIC_APEX_DOMAIN + +# The URL of the central PocketHost database. This is both a subdomain and a file name. +PUBLIC_MOTHERSHIP_URL=$PUBLIC_HTTP_PROTOCOL://pockethost-central.$PUBLIC_APEX_DOMAIN + + +# ========= +# Mothership variables (private) +# ========= -# The name of the central PocketHost database. This is both a subdomain and a file name. -PUBLIC_APP_DB=pockethost-central # The path to the root directory where all PocketHost data is stored for all users DAEMON_PB_DATA_DIR=$ROOT/.data