View Source Configuration

environment-file

Environment file

All configuration used by the app is stored in the .env file. You can find an example file in .env.sample, but you should copy it to .env and fill it with your own values (described below).

storage

Storage

VariableValuesDefaultRequiredDescription
PRESENTATION_STORAGElocal, s3local-Define where the presentation files will be stored
PRESENTATION_STORAGE_DIR-priv/static (/app/uploads for Docker)-If local storage is used, this is the directory where the presentation files will be stored. Compile-time config, so you need to recompile the app if you change it (or rebuild the Docker image).
AWS_ACCESS_KEY_ID--only for s3Your AWS Access Key ID
AWS_SECRET_ACCESS_KEY--only for s3Your AWS Secret Access Key
AWS_PRES_BUCKET--only for s3The name of the bucket where the presentation files will be stored
AWS_REGION--only for s3The region where the bucket is located

mail

Mail

VariableValuesDefaultRequiredDescription
MAIL_TRANSPORTlocal, smtp, postmarklocal-Define how the emails will be sent
MAIL_FROM-Claper-Email address used to send emails
MAIL_FROM_NAME-noreply@claper.co-Name used to send emails
SMTP_RELAY--only for smtpSMTP relay server
SMTP_USERNAME--only for smtpSMTP username
SMTP_PASSWORD--only for smtpSMTP password
SMTP_PORT-25-SMTP port
SMTP_TLSalways, never, if_availablealways-SMTP TLS
SMTP_AUTHalways, never, if_availablealways-SMTP Auth
SMTP_SSLtrue, falsetrue-SMTP SSL
ENABLE_MAILBOX_ROUTEtrue, falsefalse-Enable/disable route to local mailbox (/dev/mailbox)
MAILBOX_USER---Basic auth user for mailbox route
MAILBOX_PASSWORD---Basic auth password for mailbox route
POSTMARK_API_KEY--only for postmarkPostmark API key

application

Application

VariableValuesDefaultRequiredDescription
ENABLE_ACCOUNT_CREATIONtrue, falsetrue-Enable/disable user registration
MAX_FILE_SIZE_MB-15-Max file size to upload in MB
GS_JPG_RESOLUTION-300x300-Resolution (DPI) of the JPG generated from PDF, higher resolution means bigger files but better quality

production-docker

Production / Docker

You can use all local variables plus the following:

VariableValuesDefaultRequiredDescription
DATABASE_URL--Postgres connection string
SECRET_KEY_BASE--Generate it with mix phx.gen.secret
ENDPOINT_HOST-localhost-Host used to access the app (used for url generation)
ENDPOINT_PORT-80-Port used to access the app (used for url generation)
PORT-4000-Port to listen to