Files
Gardomatic/remote/setup/.env.example
T
kleiax 904d14b64c
CI / test (push) Canceled after 0s
Initial commit
2026-09-12 22:22:17 +02:00

85 lines
3.8 KiB
Bash

# Copy this file to .env next to provision-server.sh and restrict it to the
# administrator. The file is sourced as Bash configuration and must be trusted.
# cp .env.example .env
# chmod 600 .env
# Server provisioning ---------------------------------------------------------
# IANA timezone accepted by timedatectl. List available values with:
# timedatectl list-timezones
GARDOMATIC_SETUP_TIMEZONE='Europe/Berlin'
# golang-migrate release number without a leading "v". The script supports
# Linux AMD64 and ARM64 release archives.
GARDOMATIC_MIGRATE_VERSION='4.19.1'
# Allowed exactly: true or false. false leaves rebooting to the administrator.
GARDOMATIC_REBOOT='false'
# PostgreSQL provisioning -----------------------------------------------------
# Database and role names. Allowed: lowercase letters, digits and underscores;
# the first character must be a letter or underscore.
GARDOMATIC_DB_NAME='gardomatic'
GARDOMATIC_DB_USER='gardomatic'
# Required non-empty password used to create the PostgreSQL role. This separate
# value is not installed in the service environment, but the DSN below is also a
# secret because it normally contains the same password.
GARDOMATIC_DB_PASSWORD=''
# Application runtime ---------------------------------------------------------
# Allowed: development, test, production. Keep production on public servers.
GARDOMATIC_ENV='production'
# Required PostgreSQL connection string. Percent-encode URI-reserved characters
# in the password. Example form:
# postgres://gardomatic:ENCODED_PASSWORD@localhost:5432/gardomatic?sslmode=disable
GARDOMATIC_DB_DSN=''
# Connection-pool limits. Open must be at least 1; idle must be between 0 and open.
GARDOMATIC_DB_MAX_OPEN_CONNS='25'
GARDOMATIC_DB_MAX_IDLE_CONNS='25'
# Go duration, for example 30s, 15m or 1h30m.
GARDOMATIC_DB_MAX_IDLE_TIME='15m'
# Listener hosts. Use 127.0.0.1 behind a reverse proxy; an empty value listens on
# all available interfaces. Ports must be integers from 1 to 65535.
GARDOMATIC_API_HOST='127.0.0.1'
GARDOMATIC_API_PORT='4000'
GARDOMATIC_WEB_HOST='127.0.0.1'
GARDOMATIC_WEB_PORT='4040'
# Absolute internal API URL used by the web process.
GARDOMATIC_API_BASE_URL='http://127.0.0.1:4000'
# Required absolute public HTTP(S) URL. Use HTTPS and normally no path in production.
GARDOMATIC_WEB_BASE_URL=''
# Non-empty cookie name shared by API and web.
GARDOMATIC_SESSION_COOKIE_NAME='gardomatic_session'
# Go durations, for example 30m, 12h or 168h. Use positive values.
GARDOMATIC_SESSION_LIFETIME='12h'
GARDOMATIC_SESSION_IDLE_TIMEOUT='30m'
# Boolean. Accepted true values: 1, t, T, TRUE, true, True. Accepted false
# values: 0, f, F, FALSE, false, False. Must be true in production.
GARDOMATIC_COOKIE_SECURE='true'
# Boolean with the same accepted forms as GARDOMATIC_COOKIE_SECURE.
GARDOMATIC_RATE_LIMIT_ENABLED='true'
# Positive requests per second; decimal values such as 0.5 are accepted.
GARDOMATIC_RATE_LIMIT_RPS='10'
# Positive integer defining the permitted request burst.
GARDOMATIC_RATE_LIMIT_BURST='40'
# Comma-separated absolute URLs; every entry requires a scheme and host. Empty
# allows no cross-origin browser access. Use origins without paths, for example:
# https://garden.example.com,https://admin.example.com
GARDOMATIC_CORS_TRUSTED_ORIGINS=''
# Delivery mode. Allowed exactly: file or smtp. Production normally uses smtp.
GARDOMATIC_SMTP_MODE='smtp'
# Required in smtp mode: resolvable SMTP hostname and TCP port.
GARDOMATIC_SMTP_HOST=''
GARDOMATIC_SMTP_PORT='587'
# Required non-empty credentials in smtp mode.
GARDOMATIC_SMTP_USERNAME=''
GARDOMATIC_SMTP_PASSWORD=''
# Required sender mailbox in smtp mode, for example gardomatic@example.com.
GARDOMATIC_SMTP_SENDER=''
# Writable absolute path required only when GARDOMATIC_SMTP_MODE=file.
GARDOMATIC_SMTP_FILE_PATH='/tmp/gardomatic-mails.log'